# The Mike-Farmer Model (2008)

In the publication of Farmer et al. (2006) in the Future Enhancement chapter, there were announced important properties of the order flow for a future upgrade of the model. Parts of these features were introduced in Mike and Farmer (2008). We call this model the MF model. This model was distinguished from the previous one in:

• Trending of order flow

• Power placement of limit prices

• Non-Poisson order cancellation process

Later, this model was upgraded and analyzed in Chakraborti et al. (2011), Gu and Zhou (2009), and He and Wen (2013). The first and most important assumption that signifies order flow is a long memory process (Bouchaud et al. 2004; Lillo and Farmer 2004; Lillo et al. 2005).

The first step for the construction of the model is the estimation of the Hurst exponent using methods in Achard and Coeurjolly (2009) and realized in the package dvfBm of the R environment (for the estimated parameters see Table 2).

Another important point in this research is the distribution of the order price. For all the variables we use the same names as in Mike and Farmer (2008). In calculating and fitting the relative distance from the best price (the best bid for buying orders and the best ask for selling orders) we find that Student’s t-distribution is not the best theoretical distribution for the description of our data. The positive tail of distribution is quite definitely less than the theoretical tail of distribution. This means that effective market orders will appear more often than in reality (see Fig. 3). The negative tail of distribution does not differ too greatly from the theoretical values, but it does describe the power-law tail of order price (see Fig. 2b).

 Parameters Description Value Hs Hurst exponent of the order sign series 0.73 «X Degrees of freedom of the order placement distribution 2.08 ax ■10_3 Scale parameter of the order placement distribution 6.76 A Parameter for the equation of order cancellation 0.0167 B Parameter for the equation of order cancellation 57.12 D1 Parameter for the equation of order cancellation 0.283 D2 Parameter for the equation of order cancellation 27.4 T Tick size 0.01 This crude assumption of our data can lead to bigger spreads than in reality, and bigger returns, because the number of effective market orders would be more, and these orders take away liquidity from the market. Later in our research, we try to upgrade a theoretical description of this distribution.

In the MF model there are advanced cancellation processes, which differ from the Poisson process. We calculate probability conditioned on position in the order book as in the original paper (see Fig. 4).  We find that we are not able to have a good fit of this curve without redesigning the functional form as:

After the estimation parameters, we calculated another important factor, which determined an imbalance between buyers and sellers on the market: order book imbalance (see Fig. 5).

After that we try to estimate probability conditioned on number of orders in the order book and it was very surprising for us, because in Mike-Farmer data there was inverse relationship (see Fig. 6).

In order to fit our data we bring an analytical form for the curve as in the process conditioned on the position in the order book. Total conditional probability was calculated as:  P ^Ci yi; nimb; nto^ — A (1 Fig. 6 The probability of cancellation conditioned on number of orders in the order book

At each step (in our case, each second) we generate one order with sign, volume and price. After that, we calculate the conditions of the order cancellations. For details of this realization see He and Wen (2013). It is interesting that during the process of evolution, the structure of the financial market has undergone changes, especially with the emergence of high frequency and algorithmic trading. Now algorithms trade on financial markets at the “speed of light,” and many orders are cancelled after the fact of entry onto the market. Most orders in our sample close after their submission and so the probability of cancellation is very high.