Skip to content
All library documents

Estimating Realized Spread from Coarse Trade Data

Article Quant Q&A · Author: shoonya

Summary

The document asks whether second-level open, high, low, close, volume, and VWAP data can estimate a stock’s realized spread. It defines the conventional measure using each execution’s price and the quote midpoint five minutes later, with buy and sell signs handled separately and executions weighted by shares. Because the supplied bar data lack trade-level direction, execution prices, and later midpoint quotes, they cannot support that direct calculation.

An alternative proposed method uses squared differences between a period’s close and later VWAP observations across time delays. A regression of these squared differences on delay and a constant is intended to separate price evolution variance from instantaneous execution-price variance; volume can weight observations. The answer favors close, VWAP, and volume, and cautions that highs and lows may be outliers or filtered. This is an indirect estimator with assumptions about timing and variance, not a direct realized-spread measurement. A second answer suggests simple bar-based proxies, but these do not reproduce the standard quote-based definition.

Key ideas

  • The standard realized spread compares execution price with the later bid–ask midpoint and weights executions by shares.
  • Bar summaries do not contain the transaction-level and quote data needed for that direct measure.
  • A regression across time delays of squared close-to-later-VWAP differences is proposed to separate variance components.
  • Volume can serve as a weight, while high and low prices may be unreliable inputs.
  • Simple high–low or open–close measures are only rough proxies for realized spread.

Tags

Full text
# Estimate of realized spread


# Estimate of realized spread












Given a dataset with second level information about open, high, low, close, volume and vwap of a stock - how can one estimate the realized spread - a simple estimate could be (high - low)- but can one use open and close to get a better estimate and moreover - VWAP and volume ?

```
  id                  symbol    timestamp open_price close_price   low  high volume  vwap
1 2009-01-01 09:00:12 XXXXXXXXX EQ              70.2        70.2  70.2  70.2      3  70.2
2 2009-01-01 09:00:33 XXXXXXXXX EQ              70.2        70    70    70.2     25  70.2
3 2009-01-01 09:00:37 XXXXXXXXX EQ              69.8        70    69.8  70      491  69.8
4 2009-01-01 09:00:43 XXXXXXXXX EQ              70.5        70.0  70.0  70.5    225  70.4
5 2009-01-01 09:00:47 XXXXXXXXX EQ              70.4        70.4  70.4  70.4    200  70.4
6 2009-01-01 09:00:49 XXXXXXXXX EQ              70.4        70.4  70.4  70.4     50  70.4
```

## Answer by krkeane (score 2)

https://quant.stackexchange.com/a/77330

US SEC Rule 605 defines "average realized spread" as the share-weighted average of realized spreads for orders executions calculated, for buy orders, as double the amount of difference between the execution price and the midpoint of the consolidated best bid and offer five minutes after the time of order execution, for sell orders, as double the amount of difference between the midpoint of the consolidated best bid and offer five minutes after the time of order execution and the execution price.

$$ \text{ARS} = \frac{2 \left(\sum\limits_{i\in\text{Buy}} \text{shares}_i \left(\text{price}_{i} - \text{mid}_{\text{time}(i) + 5}\right) +\sum\limits_{i\in\text{Sell}} \text{shares}_i \left(\text{mid}_{\text{time}(i) + 5} - \text{price}_{i}\right)\right)}{\sum\limits_{i=1}^n \text{shares}_i } $$ Your data set does not have transaction level detail required for the above sum.

`nbbo2` points to Corwin and Schultz. In Corwin and Schultz section 1,

> While the variance component grows proportionately with the time period, the spread component does not.

A simple regression will tease these two components (variance due to change in midspread, and variance around midspread) apart. For example, with minutely data, consider the regression:

$$ \begin{align} \text{Fit} \quad \left( \text{close}_{t} - \text{vwap}_{(t+s)}\right)^2 \quad &\text{by} \quad s +\text{constant}\quad\forall t, ~s \in 0, 15,30,60,\ldots \\ \text{Fit} \quad y &= mx + b \\ \hat{m} &= \text{est. variance of midspread / minute} \\ \hat{b} &= \text{est. variance around midspread} \\ \sqrt{\hat{b}} &= \text{est. std. dev. of execution prices due to ARS} \end{align} $$

In state space model terminology, the distinction here is between evolution variance impacting the midspread over time and observation variance impacting a single execution instantaneously. See West, Mike, and Jeff Harrison. "The dynamic linear model." Bayesian forecasting and dynamic models (1997): definition 1.1.

Weighted least squares could include volume data: $$ \begin{align} i &= \text{enumerates observations } \forall s,t\\ w_{i,i} &= \text{shares}_i,\text{ diagonal matrix element} \\ y_{i} &= \left( \text{close}_{t} - \text{vwap}_{(t+s)}\right)^2 \\ x_{i} &= \left[s_i, 1\right],\text{ time delay } s \text{ and constant} \\ \hat{\boldsymbol{\beta}} &= (X^\textsf{T} W X)^{-1} X^\textsf{T} W \mathbf{y} \end{align} $$

This answer drops open, high, low; and keeps close, volume, vwap.

Depending on the time interval $t$, the stock, and the execution facility, open may be the same execution as close, so I also avoid using both $open_t$ and $close_t$.

High and low are outliers, and worse, potentially filtered or manipulated by execution facilities for competitive or legal reasons. Therefore, high and low reported may not be high and low in the unrestrained setting assumed by estimators.

In very liquid stocks, the last trade of one period occurs at about the same time as the first trade of the next period, so evolution variance between adjacent trades is approximately zero, and the sum of observation variance for the two trades is approximately: $\textrm{Var}\left(\text{close}_{t-1}-\text{open}_{t}\right) \approx 2 \sigma_{\text{spread}}^2$

## Answer by Amit Kumar Jha (score 1)

https://quant.stackexchange.com/a/77097

The realized spread is a measure of market liquidity and is often calculated as the difference between the transaction price and the midpoint of the bid-ask spread some time

t after the trade. The typical formula to calculate the realized spread is:

## Realized Spread

Transaction Price − Midpoint of Bid-Ask Spread at Time

Realized Spread=Transaction Price−Midpoint of Bid-Ask Spread at Time t However, you're asking for an estimate based on the available data: open, high, low, close, volume, and VWAP (Volume Weighted Average Price).

Here are a few ways to estimate the realized spread with these parameters:

Using High-Low: The simplest estimate, as you mentioned, is High − Low High−Low.

Using Open-Close: Another estimate can be made by taking the absolute difference between the open and close prices:

## Realized Spread Estimate

∣ Open Price − Close Price ∣ Realized Spread Estimate=∣Open Price−Close Price∣ Using VWAP: The VWAP can be used to estimate the "average" price at which transactions occurred during that time interval. You can use the difference between the VWAP and either the high or low as another estimate:

## Realized Spread Estimate

VWAP − Low Realized Spread Estimate=VWAP−Low or

## Realized Spread Estimate

High − VWAP Realized Spread Estimate=High−VWAP Using Volume: Volume could potentially be used as a weighting factor for the other estimates to give more importance to intervals with higher trading activity.

Shown in full with attribution under the source's licence. Licence: CC BY-SA 4.0 (Stack Exchange)

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