# Roll Estimator and Bid–Ask Spread Decomposition

Quoted, effective and realised spreads, the Roll estimator from trade prices alone, and the split into adverse selection and the rest.

"The limit order book" defined the spread as the gap between the best ask and the best bid, and "The Glosten–Milgrom model" explained why a market maker (a trader who keeps buy and sell quotes in the book) must set it wide enough to cover losses to better-informed traders. Researchers and regulators, however, often see only a list of trade prices, without the quotes behind them. This lesson shows how much of the spread can be recovered from trade prices alone, why that estimate is biased when trading is informed, and how the spread splits into what it pays for.

Throughout, prices are in cents, $m_t$ is the efficient price (the value of the asset given everything the market has learned up to trade $t$), $S$ is the full bid–ask spread and $Q_t$ is the direction of trade $t$: $Q_t = +1$ when a buyer initiated it at the ask and $Q_t = -1$ when a seller initiated it at the bid.

## Three spreads

The quoted spread is the difference between the best ask $a$ and the best bid $b$ at a moment in time. It says what a round trip would cost a trader who buys and sells one share at once.

The effective spread measures what one actual trade cost. If a trade at price $p_t$ happens when the midpoint of the quotes is $m$, then

$$
\text{effective spread} = 2\,|p_t - m|.
$$

A buy at the ask with a one-cent half-spread has an effective spread of two cents, the same as the quoted spread; a trade inside the quotes has a smaller one.

The realised spread asks how much of that the market maker keeps once the price has had time to react. With a horizon $h$ (for example five minutes) it compares the trade price with the midpoint after the horizon:

$$
\text{realised spread} = 2\,Q_t\,(p_t - m_{t+h}).
$$

If the midpoint drifts towards the trade, as it does after informed buying, the realised spread is smaller than the effective spread. The difference is the price impact of the trade, the part of the spread lost to better-informed traders. This lesson leaves the horizon as a definition and works with the effective spread and with trade prices only.

## Bid–ask bounce

Suppose first that trades carry no information. The efficient price follows a random walk, $m_t = m_{t-1} + \varepsilon_t$ with independent shocks $\varepsilon_t$ of variance $\sigma^2$, and each trade happens at the quote on its side of the price before it:

$$
p_t = m_{t-1} + \tfrac{S}{2}\,Q_t.
$$

Directions are independent, with buys and sells equally likely. Even when $m_t$ hardly moves, the trade price jumps between the bid and the ask: a buy prints high, the next trade is a sell half the time and prints low. This is the bid–ask bounce. A price rise therefore tends to be followed by a fall, and successive price changes are negatively correlated.

## The Roll estimator

Write the price change between two trades by subtracting the expressions for $p_t$ and $p_{t-1}$:

$$
\Delta p_t = p_t - p_{t-1} = \varepsilon_{t-1} + \tfrac{S}{2}\,(Q_t - Q_{t-1}).
$$

Now take the covariance with the previous change $\Delta p_{t-1} = \varepsilon_{t-2} + \tfrac{S}{2}(Q_{t-1} - Q_{t-2})$. The shocks $\varepsilon$ are independent of everything else and of each other, and so are the directions. The only term the two changes share is $Q_{t-1}$, which enters the first with a minus sign and the second with a plus sign. With $\text{Var}(Q) = 1$:

$$
\text{cov}(\Delta p_t, \Delta p_{t-1}) = \tfrac{S}{2} \cdot \tfrac{S}{2} \cdot \text{cov}(-Q_{t-1}, Q_{t-1}) = -\frac{S^2}{4}.
$$

Solving for the spread gives Roll's estimator, which needs nothing but a series of trade prices:

$$
S = 2\sqrt{-\text{cov}(\Delta p_t, \Delta p_{t-1})}.
$$

In a sample the covariance is estimated, and noise can make it positive. Then the square root has no real value: Roll's estimator is not defined for that sample, which happens most often in short or volatile samples and is itself a sign that the estimate cannot be trusted.

## Informed trading biases Roll

Now let a share $\alpha$ of each half-spread be information. After a buy the market learns that the asset is probably worth more and the efficient price moves up by $\alpha\,S/2$; after a sell it moves down:

$$
m_t = m_{t-1} + \alpha\,\tfrac{S}{2}\,Q_t + \varepsilon_t.
$$

Trades still print at $m_{t-1} \pm S/2$, so the effective spread is still exactly $S$. The price change now becomes

$$
\Delta p_t = \tfrac{S}{2}\,Q_t - (1-\alpha)\,\tfrac{S}{2}\,Q_{t-1} + \varepsilon_{t-1},
$$

because only the part $(1-\alpha)S/2$ of the previous trade's jump reverses; the part $\alpha S/2$ stays in the price. Repeating the covariance calculation, the shared term is $Q_{t-1}$ with coefficients $-(1-\alpha)S/2$ and $S/2$:

$$
\text{cov}(\Delta p_t, \Delta p_{t-1}) = -(1-\alpha)\,\frac{S^2}{4}, \qquad 2\sqrt{-\text{cov}} = S\sqrt{1-\alpha}.
$$

Roll's estimator therefore converges to $S\sqrt{1-\alpha}$, below the true spread, while the effective spread does not move. The more informed the flow, the more of the spread is permanent price change rather than bounce, and the less of it Roll can see.

### Worked example: Roll's estimate from a covariance, and its bias

1. Price changes have a sample covariance of −0.0004 USD². Take the square root of minus the covariance.
   $$\sqrt{0.0004}$$ → **0.02**
2. Roll's spread is twice that, in USD.
   $$S = 2 \cdot 0.02$$ → **0.04**
3. Now a market with a true spread of 10¢ where $\alpha = 0.35$ of it is informed. The transitory share is $1 - \alpha = 0.65$; its square root:
   $$\sqrt{0.65}$$ → **0.80623**
4. Roll's estimator converges to this many cents.
   $$10\sqrt{0.65}$$ → **8.0623**
5. The effective spread is still 10¢, so Roll misses this many cents: the informed share at work.
   $$10 - 8.0623$$ → **1.9377**

## Decomposing the spread

If the direction of each trade is known (from quotes, or by classifying trades as buys and sells), the two parts can be separated. Rewrite the price change with $\Delta Q_t = Q_t - Q_{t-1}$:

$$
\Delta p_t = \tfrac{S}{2}\,\Delta Q_t + \alpha\,\tfrac{S}{2}\,Q_{t-1} + \varepsilon_{t-1}.
$$

This is the two-way Huang–Stoll regression $\Delta p_t = \beta_1\,\Delta Q_t + \beta_2\,Q_{t-1} + e_t$. Least squares estimates $\beta_1 = S/2$, the half-spread, and $\beta_2 = \alpha S/2$, the part of each half-spread that becomes permanent. Their ratio is the adverse-selection share

$$
\hat\alpha = \frac{\beta_2}{\beta_1}.
$$

The remaining share $1 - \alpha$ pays for order processing and for the risk of carrying inventory. This model does not separate those two; richer three-way versions add a term for how the maker's inventory changes the quotes.

## Sample size

Every estimate above is a sample average, so the law of large numbers makes it converge and "The law of large numbers and the central limit theorem" says how fast: its error shrinks like $1/\sqrt{n}$ in the number of trades. Efficient-price volatility adds noise without adding information about the spread, in the same way that volatility makes mean returns hard to pin down in "Returns and volatility". A day of 120 trades gives a rough answer; thousands of trades give a stable one.

The figure simulates this market with 120, 1,000 or 10,000 trades, draws the first 120 trades with the efficient price hidden, and plots each price change against the previous one with its least-squares line. Start at the defaults: a 10¢ spread, $\alpha = 0.35$ and 2.5¢ of efficient-price volatility per trade. With 120 trades Roll's estimate is 9.66¢, close to 10¢ by luck rather than by design, and Huang–Stoll's $\hat\alpha$ is 27.9%. Switch to 10,000 trades: Roll settles at 8.28¢, near its limit of 8.06¢ and 17.2% below the true spread, $\hat\alpha$ moves to 34.6%, and the effective spread stays at 10¢ throughout. Then set $\alpha$ to 0 and watch the gap close, and raise the volatility to see the 120-trade estimate jump around.

*[Interactive figure: roll bounce](https://quantsandbox.dev/guide/microstructure/spread-measurement)*

> Roll needs only prices but sees only the transitory part of the spread. The effective spread needs the quotes and sees all of it. The gap between them is a measure of informed trading.

## Summary

- The quoted spread is $a - b$, the effective spread of a trade is $2|p_t - m|$, and the realised spread $2Q_t(p_t - m_{t+h})$ is what the maker keeps after a horizon $h$.
- Trades bounce between bid and ask, so successive price changes have covariance $-S^2/4$ and Roll's estimator is $S = 2\sqrt{-\text{cov}}$; it is not defined when the sample covariance is positive.
- When a share $\alpha$ of each half-spread is information, the covariance shrinks to $-(1-\alpha)S^2/4$ and Roll converges to $S\sqrt{1-\alpha}$, while the effective spread stays $S$.
- With known trade directions, the Huang–Stoll regression estimates the half-spread $\beta_1$ and the adverse-selection share $\beta_2/\beta_1$.
- Estimates from a few hundred trades are noisy; their error shrinks like $1/\sqrt{n}$.

[Open the Spread Estimation lab](https://quantsandbox.dev/spread-estimation)

## Interactive labs

- [Bid-Ask Spread Estimation: Roll and Effective](https://quantsandbox.dev/spread-estimation)

## Practice questions

### 1. The sample covariance of successive price changes is −0.0009 (in USD²). What spread in USD does Roll's estimator give?

**Answer:** 0.06

$S = 2\sqrt{0.0009} = 2 \cdot 0.03 = 0.06$ USD, six cents.

### 2. Traders become better informed, so the share α of the spread that is information rises. What happens to Roll's estimate?

- a) It falls below the true spread
- b) It rises above the true spread
- c) It stays unbiased
- d) It becomes negative

**Answer:** a) It falls below the true spread

Only the transitory part $(1-\alpha)$ of each jump reverses, so the covariance shrinks to $-(1-\alpha)S^2/4$ and Roll converges to $S\sqrt{1-\alpha}$.

---

Source: https://quantsandbox.dev/guide/microstructure/spread-measurement

Previous lesson: [Glosten–Milgrom Model: Spreads from Informed Trading](https://quantsandbox.dev/guide/microstructure/glosten-milgrom)

Next lesson: [Kyle Model and Kyle's Lambda: Insider Price Impact](https://quantsandbox.dev/guide/microstructure/kyle-model)
