# What sort of order submission strategy would result in a random walk of trade prices?

I have written a simulation that matches buy and sell orders, keeps track of an order book and simulates trades. My first pass at order submission was to generate random orders around the bid/ask spread. This does not produce a random walk in trade prices. What happens is the orders are distributed evenly but around the bid/ask spread they get traded out but beyond this they start clumping together thereby forming 'price resistance'for want of a better word. Is there an algorithm I can use that will result in a random walk for trade prices?

-

## 2 Answers

You have intense academic research on orderbook dynamics simulations, just cite:

(1) is a generic survey, (2) provides you a way to build consistent simulations and different scales (i.e. controlling the volatility, the bid-ask spread and their relation along the whole day), (3) is more local but allow to simulate a consistent way the order flow dynamics and the price one.

One simple way to improve you simulations is to:

• have a model for the bid-ask spread
• choose Point processes (Poisson or better: Hawkes) to model the input and output in the queues
• use Rama's model to generate a price: when a queue (Bid or Ask) equals zero, move the price (down or up)

If you want to have proofs that the diffusive limit of a point process will be a Brownian motion, you can read for example:

-

Analyzing this question theoretically, I think the following strategy will result in a random walk.

1. the average size of limit orders is much smaller than the average size of market orders;
2. the size of market order is random, and subjects to a kind of distribution;
3. market buy orders and market sell orders arrive at random but evenly;
4. the size of limit order subjects to a kind of distribution.

I do not know your strategy by detail, so I am not sure if your have considered the above items already. But by guess, it may be the first requirement that bothers you. Too many limit orders on the best-bid / best-ask seems tend to prevent market prices from change. In fact, as long as limit orders at best-bid / best-ask have the opportunity to be exhausted, the simulation strategy will generate a random walk, you just need a longer time to watch the price to walk away. Any way, it can still be called a "random walk".

-