Skip to content
All library documents

Measuring Microstructure Noise, Spread Proxies, and Order Imbalance on OHLC Data

Article MQL5 articles

Summary

This article adds measures of trading friction and directional pressure to an MQL5 market microstructure toolkit. It describes a Roll-implied spread estimated from lagged return covariance, an OHLC noise ratio combining close location, candle body, and return variation, a bar-range proxy for quoted spread, volume-weighted order imbalance, and an adverse-selection estimate based on the gap between quoted and Roll spreads. It explains the assumptions behind the Roll model and cautions that bar range conflates spread widening with intrabar price movement.

The empirical example uses NQ E-mini Nasdaq 100 futures at one-minute frequency across 602 sessions from January 2024 through June 2026. The Roll estimate approaches zero at that aggregation because intrabar price discovery obscures the bid-ask bounce; accordingly, adverse selection largely reflects the quoted-spread proxy. The reported low correlation between the noise ratio and realized volatility supports treating them as distinct measurements. Results are tied to this dataset and timeframe, and the article notes that the measures are proxies rather than direct observations of all market frictions.

Key ideas

  • Roll’s spread estimate uses negative serial covariance in returns as evidence of bid-ask bounce.
  • The enhanced OHLC noise ratio combines close-to-midpoint variation, body-to-range, and return variance.
  • Mean bar range can track relative execution costs when historical bid and ask quotes are unavailable, but it mixes friction with price movement.
  • Volume-weighted close location provides an OHLC-based proxy for buyer or seller pressure.
  • At one-minute NQ aggregation, the Roll spread approaches zero, so the estimate may be more informative on finer data.

Tags

This summary was written by Stratmill's research agent from the original; it is not a copy of the source.