Advanced Empirical Finance: Topics and Data Science

High-frequency econometrics

Stefan Voigt

University of Copenhagen and Danish Finance Institute (DFI)

Spring 2026

High-frequency trading

High-frequency trading

  • So far, we have focused on quarterly, monthly, or daily price observations
  • But: There is much more under the surface!
  • High-frequency trading is a type of algorithmic financial trading characterized by high speeds, turnover rates, and order-to-trade ratios that leverages high-frequency financial data and electronic trading tools

Relevance for asset pricing

  1. liquidity (transaction costs)
  2. price informativeness (have you asked yourself how information makes it into prices?)
  3. more information may be beneficial for volatility estimation
  4. wasteful investments?

Quick primer on equity microstructure

  • Market structure across asset classes can vary tremendously
  • Large heterogeneity across US equity markets (lit pools, dark pools, maker-taker, …)
  • Standard framework: Continuous limit order book
  • Limit orders indicate a willingness to buy/sell at a pre-specified price
  • Market orders execute against limit orders
Figure 1

A typical NASDAQ trading day

Opening auction

Continuous trading Cancellations, submissions, executions; hidden or lit orders

Closing auction

Overnight trading

How to get high-frequency trading data at KU

  • As a member of KU, you can retrieve data from Lobster
  • Lobster is a limit order book data provider with easy-to-use, high-quality limit order book data for the entire universe of NASDAQ traded stocks
  • Lobster files contain all messages for a pre-specified ticker that went through NASDAQ servers

Practical comments

  • Listing exchange does not matter - most stocks listed on NYSE also trade on NASDAQ!
  • Output: zipped .7z file. archive package or 7-Zip file manager (Windows), 7z (Linux), Unarchiver (Mac)
  • Useful for many files: You can download files from the command line with
wget -bqc -P destination_folder ftp://username:password@lobsterdata.com/user_id/*

Historical perspective on high-frequency (ETF) trading data

Realized volatility

HFT: Approaching continuous time finance

  • Does it help to use data sampled at a high frequency to estimate \(\mu_t\) and \(\sigma_t^2\)?
  • Continuous-time finance helps
  • Well-known example: Geometric Brownian motion (stock price movements are additive on the log scale) \[ \log(P_t) = X_t = X_0 + \mu t + \sigma W_t \]

where \(W_t\) is a Brownian motion

Brownian motion

The process \((W_t)_{0\leq t\leq T}\) is a Brownian motion provided that

  1. \(W_0 = 0\)
  2. \(t \rightarrow W_t\) is a continuous function of \(t\)
  3. \(W\) has independent increments and for \(t>s\), \(W_t - W_s\) is normal with mean zero and variance \(t-s\)

Brownian motion: discrete sampling

  • Suppose \(t = 0\) is the start of the trading day and \(t=1\) is the end of the day
  • Assume there are \(n\) equidistant observations (transactions) of the log price
  • One observation every \(\Delta_{t_n} = 1/n\) units of time
  • We observe \(X_{t_{n,i}}\) with \(t_{n,i} = i\Delta t_n\) and get \[\Delta X_{t_{n,i}} = X_{t_{n,i}} - X_{t_{n,i -1}} \]
  • By definition of the BM, the \(\Delta X_{t_{n,i}}\) are iid normal \(N(\mu\Delta t_n, \sigma^2 \Delta t_n)\)

Simulation of a Brownian motion

price = cumsum(c(
  start,
  rnorm(steps, mean = mu / steps, sd = sigma / sqrt(steps))
))
Figure 2

Estimating \(\mu\) and \(\sigma^2\) in the GBM model

  • The natural estimator for \(\hat\mu\) is \[\hat\mu_n = \frac{1}{n\Delta t_n}\sum\limits_{i = 0}^{n-1}\Delta X_{t_n, i+1} = (X_1 - X_0)\]
  • (Maybe) surprising: \(\hat\mu_n\) does not depend on the sampling frequency. Consistent estimation requires \(t\rightarrow \infty\)
  • (Maybe) more surprising: \(\hat\sigma^2\) can be estimated consistently as \(n\rightarrow \infty\)!
  • Set \(U_{n,i+1} = \Delta X_{t_n,i+1}/(\sigma\Delta t_n^{1/2}) \sim N\left(\frac{\mu}{\sigma}\Delta t_n^{1/2}, 1\right)\) and define the sample mean \(\bar U_n = \frac{1}{n}\sum\limits_{i = 0}^{n-1} U_{n,i+1}\)
  • Then \[\begin{aligned}\hat\sigma_n^2 &= \frac{1}{(n-1)\Delta t_n}\sum\limits_{i = 0}^{n-1}\left(\Delta X_{t_n, i+1} - \bar{\Delta X_{t_n}}\right)^2 \\&= \frac{\sigma^2\Delta t_n}{(n-1)\Delta t_n}\sum\limits_{i = 0}^{n-1}\left(U_{n, i+1} - \bar U_n\right)^2 \stackrel{\mathcal{L}}{=} \sigma^2\frac{\chi^2_{n-1}}{n-1}\end{aligned}\]
  • It follows that \(E\left(\hat\sigma_n^2\right) = \sigma^2\) and \(\text{Var}\left(\hat\sigma_n^2\right) = \frac{2\sigma^4}{n-1}\)

Non-centered estimator

  • For high-frequency data, the mean \(\bar{\Delta X_{t_n}}\) is often not removed in estimation
  • Instead, consider \[\hat\sigma^2_{n,\text{nocenter}} = \frac{1}{n\Delta t_n}\sum\limits_{i=0}^{n-1}\left(\Delta X_{t_{n, i +1}}\right)^2 = \frac{n-1}{n}\hat\sigma_n^2 + \Delta t_n\hat\mu_n^2 = \frac{n-1}{n}\hat\sigma_n^2 + \frac{1}{n}\hat\mu_n^2 \]
  • Since \(\hat\mu_n\) does not depend on \(n\), it follows that \(\hat\sigma^2_{n,\text{nocenter}}\) is also consistent

Realized variance

  • Assume \(\mu_t\) and \(\sigma_t>0\) are predictable processes of finite variation driving the diffusion \[dX_t = \mu_t dt + \sigma_t dW_t.\]
  • Then the continuously compounded return over \([t-k, t]\) is \[r(t,k) = X_t - X_{t-k} = \int\limits_{t-k}^t \mu_s ds + \int\limits_{t-k}^t \sigma_s dW_s\]
  • The diffusive sample path variation is called the integrated variance \[IV(t-k, k) = \int\limits_{t-k}^t \sigma_s^2 ds \]
  • Define the realized variance as \(RV^{(n)} := \sum\limits_{i=0}^{n-1}r_{i,n}^2\)
  • As long as there are no jumps, \(RV^{(n)} \rightarrow IV(0, 1)\) as \(n\rightarrow\infty\)
  • ‘Infill’ asymptotics: sampling at the highest possible frequency is crucial!

Infill asymptotics

Realized variance of the S&P 500

read_csv("../data-r/rv-data.csv", show_col_types = FALSE) |>
  ggplot(aes(x = Date, y = `Realized Variance (1-min)`)) +
  geom_line() +
  theme_bw()
Figure 3

Market Microstructure Noise

Market Microstructure Noise

  • Problem in practice: market microstructure frictions
  • E.g., bid-ask spreads, price discreteness, asymmetric information, strategic order placement
  • We can only observe \[Y_{i\Delta n} = X_{i\Delta n} + U _{i\Delta n}\] where \(Y_{i\Delta n}\) is the observed (log) transaction price or quote, \(X_{i\Delta n}\) is the efficient latent (log) price
  • \(U_{i\Delta n}\) is white noise which captures microstructure frictions

Microstructure noise: the intuition

  • So far: the highest possible sampling frequency is optimal

Microstructure noise: the problem

  • Now: what is the RV estimator’s optimal sampling frequency/adjustment in the presence of microstructure noise?

Microstructure noise: formal setup

  • For now, consider the simplest case with \(X_t = \sigma W_t\) and \(\tilde X_t = X_t + U_t\) where the \(U_t\) are iid noise with zero mean and variance \(a^2\)
  • Then \[\begin{aligned}Y_{\tau_i} &= \tilde X_{\tau_i} - \tilde X_{\tau_{i-1}} \\&= \left(X_{\tau_i} - X_{\tau_{i-1}}\right) + U_{\tau_i} - U_{\tau_{i-1}} \\&= \sigma \left(W_{\tau_i} - W_{\tau_{i-1}}\right) + U_{\tau_i} - U_{\tau_{i-1}}\end{aligned}\]
  • We get \(\text{Var}\left(Y_{\tau_i}\right) = \sigma^2\Delta_n + 2a^2\) and \(\text{Cov}\left(Y_{\tau_i}, Y_{\tau_{i-1}}\right) = -a^2\)
  • The proportion of the total return variance that is market microstructure-induced is \[\pi = \frac{2a^2}{2a^2 + \sigma^2\Delta_n}\]
  • As \(\Delta_n\) gets small, a larger fraction of the observed return variance is noise-driven
  • Noise bias adjustment possible (Ait-Sahalia et al., 2005)

Bid-ask bounce and the volatility signature plot

Figure 4: A simulated bid-ask bounce example. The left panel shows the volatility signature plot: realized variance is inflated at very high sampling frequencies because observed prices contain microstructure noise. The right panel shows that bid-ask bounce induces negative first-order autocovariance in observed returns.

Volatility signature plot: S&P 500

Figure 5: Volatility signature plot for S&P 500 high-frequency midquotes. Each point reports the average daily realized variance computed at a different calendar-time sampling interval; higher estimates at very fine intervals indicate the influence of market microstructure noise.

Optimal sampling frequency

  • Optimal sampling frequency depends on the signal-to-noise ratio \(\pi\)

Two-scale realized variance

  • Sparse sampling reduces noise bias but lowers efficiency: we throw away data
  • Zhang, Mykland, and Ait-Sahalia (2005) propose a two-scale realized variance estimator based on
    1. sub-sampling
    2. averaging
    3. bias correction
  • Start from observed noisy prices \(Y_0,\ldots,Y_n\)
  • Split the data into \(K\) sparse sub-samples: \[G^{(k)} = \left\{Y_k, Y_{k+K}, Y_{k+2K}, \ldots\right\}, \quad k=1,\ldots,K\]
  • Compute realized variance on each sparse grid and average: \[RV^{\text{avg}}_K = \frac{1}{K}\sum_{k=1}^K RV^{(k)}\]
  • Correct the remaining noise bias using the all-data realized variance: \[TSRV = RV^{\text{avg}}_K - \frac{\bar n_K}{n}RV^{\text{all}}\]

where \(\bar n_K\) is the average number of returns per sparse grid.

TSRV example with second-level data

Figure 6

Realized Covariances

  • Similar in spirit – the efficient log-price process follows an \(N\)-dimensional Brownian semimartingale \[X_t = \int\limits_{0}^t a_u du + \int\limits_{0}^t \sigma_u dW_u\] where \(a\) is a predictable locally bounded drift process, \(\sigma_u\) is a volatility matrix process, and \(W\) is a vector of independent Brownian motions
  • If \(X_t\) is discretely observed, a natural estimator for the quadratic covariation is \[RC_n = \sum\limits_{i=1}^n\left(X_{i/n} - X_{(i-1)/n}\right)\left(X_{i/n} - X_{(i-1)/n}\right)'\]
  • Similar concept for realized betas \[R\beta_i = \frac{RC_{ip,n}}{RC_{pp,n}}\] where \(p\) corresponds to the market portfolio

Challenges in covariation estimation

  • Positive definiteness: can we invert the covariance matrix?
  • Conditioning: are matrix inversions numerically stable?
  • Efficiency: are we throwing away too much data due to sparse sampling?
  • Market microstructure effects
  • Asynchronicity of observations in time: Epps (1979, JASA)

Multivariate Realized Kernels

  • How to handle asynchronous trading?

  • Definition: Refresh time for \(t\in[0,1]\). Define the first refresh time as \(\tau_1 = \max\left(t_1^{(1)}, \ldots, t_1^{(N)}\right)\). For each asset \(i\), let \(N_j^{(i)} = \min\left\{k: t_k^{(i)} > \tau_j\right\}\) be the next observation after \(\tau_j\); then define iteratively \[\tau_{j+1} = \max\left(t_{N_j^{(1)}}^{(1)}, \ldots, t_{N_j^{(N)}}^{(N)}\right) \]
  • Compute synchronized returns based on \(\left\{\tau\right\}\)

High-frequency-based covariance matrix estimation

  • Overcome asynchronicity by refresh time sampling: \[\begin{aligned}r\tau _{t,1}:=\max_{i}\left\{\tau_{t,1} ^{(i)}\right\}, \quad r\tau _{t,l+1}:=\max_{i}\left\{\tau_{t,N^{(i)}(r\tau _{t,l})} ^{(i)}\right\}\end{aligned}\]

  • Realized kernel (Barndorff-Nielsen et al., 2011): \[\begin{aligned} K_t := \sum\limits_{h=-H_t } ^{H_t } k\left(\frac{h}{H_t +1 }\right) \Gamma_t ^{h}, \end{aligned}\] where \[\begin{aligned} k(x) = \left\lbrace \begin{array}{ll} 1 - 6x^{2} + 6x^{3} & 0 \leq x \leq 1/2\\ 2(1-x)^{3} & 1/2 \leq x \leq 1\\ 0 & x > 1 \end{array}\right.\end{aligned}\] \(\Gamma_t ^{h}\) is the \(h\)-lag auto-covariance matrix based on refresh-time synchronized returns, and \(H_t\) is a block-specific bandwidth.

Blocked Realized Kernels

  • Blocked and regularized realized kernel (Hautsch et al., 2012)
  • Idea: gaining efficiency and tractability in high dimensions by blocking
  • Stocks ordered according to the average of daily mid-quotes
  • 4 equal-sized groups result in \(b=10\) covariance blocks
  • Compute realized kernel for each covariance block: \(K_t^b\)

Blocked Realized Kernels

  • Ensure scale invariance by computing correlation blocks, \[\hat{H}_t^\text{b} = \left(V_t ^\text{b}\right)^{-1} K_t ^\text{b} \left(V_t ^\text{b}\right)^{-1},\hspace{1 cm}V_t ^\text{b} = \text{diag }\left[K_t ^{b}\right]^{1/2}\]

  • Yields covariance estimator: \[\hat{\Sigma}_t^\text{BRK} = \text{diag} \left(\hat\sigma^2 _{t,1},\ldots,\hat\sigma^2 _{t,N}\right)^{1/2} \hat{H}_t \text{diag} \left(\hat\sigma^2 _{t,1},\ldots,\hat\sigma^2 _{t,N}\right)^{1/2}\]

  • Averaging over the last five days: \[\hat{\Sigma}_{S,t} ^{BRK} := (1/5)\sum_{s=1}^5 \hat{\Sigma}_{t-s+1} ^{BRK}\]