Order flow: from Poisson to Hawkes.
A limit order book is a queueing system: limit orders post liquidity, market orders consume it, cancellations withdraw it. Everything then hinges on one question: how do those events arrive in time? This page builds the book from raw Euronext tick data, then drives it with three increasingly honest models of the flow.
The book is a queue
Working from several full days of tick-by-tick transactions and order book states for a Euronext stock, a handful of robust stylised facts emerge: trade durations are heavier-tailed than exponential (a Weibull with shape < 1, much mass below 100 ms), trade sizes follow a power law with , the volatility signature plot blows up at small scales from bid-ask bounce, and order-flow imbalance at the touch predicts the next mid-price move. Here we take those measurements as given and ask what generates them.
How much of this needs intelligent agents? Surprisingly little. A zero-intelligence book (Smith-Farmer style) where every order is pure noise, governed by three Poisson rates,
already reproduces a realistic average book shape, a fluctuating spread and a diffusive mid-price. The panel below is that engine three ways: the mid-price tape, a classic trading ladder (the DOM, last trade marked) and the resting depth. Push μ up and the book thins and the spread widens; push λ up and liquidity rebuilds.
(green = buyer-initiated,
red = seller-initiated)
Flow model 2: a time-varying Poisson
The naive book assumes a constant arrival rate. Real flow is nothing like it. Averaging trades per five-minute bin over a month of data gives a textbook intraday U-shape: a hot open, a quiet lunch, a busy close. The honest upgrade is an inhomogeneous Poisson process with a deterministic intensity fitted to that curve (cubic spline or polynomial), then simulated by Ogata thinning: draw a homogeneous process at rate and keep each point with probability .
The figure reproduces that benchmark: the white line is the (noisy) empirical intensity, the blue curve the fitted , and the bars are one thinning realisation binned back to five minutes - it traces the U it was built from. The dashed line is the homogeneous rate the naive book would have used: right on average, wrong at every moment of the day.
Flow model 3: self-exciting Hawkes
A time-varying captures the predictable shape of the day, but not the clustering: a trade begets trades on a timescale of milliseconds to seconds. No Poisson model, homogeneous or not, can do that - its intensity never reacts to its own history. A Hawkes process can, with one feedback term:
Every event lifts the intensity by , decaying at rate . The key number is the branching ratio , the expected children per event; as the flow becomes dominated by endogenous cascades. On equity order flow sits close to one: the market mostly reacts to itself. Below, the live simulator (Ogata thinning) shows the intensity its own events generate.
Poisson vs Hawkes, same average rate
Hold the same mean rate and compare. The Poisson tape is featureless; the Hawkes tape alternates droughts and avalanches. The one-number summary is the Fano factor, variance over mean of the bin counts: Poisson sits at 1 at every scale, while real order flow (and Hawkes as ) is strongly over-dispersed. Feed a Poisson-calibrated execution model into a Hawkes world and it will underestimate queue depletion exactly when it matters - during the bursts.
Calibration & validation
Both upgraded models are fitted on real trade timestamps by maximising the point-process log-likelihood:
and validated with the time-rescaling theorem: if the model is right, the compensated inter-event times are i.i.d. exponential, testable with a Kolmogorov-Smirnov statistic. On the Euronext data the exponential-kernel Hawkes fit passes where a plain Poisson model is rejected outright, and the fitted branching ratio comes out high - strong endogeneity in the flow.