What does Liquidation Cascades and Cointegration conclude, in numbers, about “The Ornstein–Uhlenbeck Process: Mean Reversion and Its Estimation”?
Answer: The OU process \(\mathrm{d}X = \theta(\mu - X)\mathrm{d}t + \sigma\mathrm{d}W\) discretises exactly into an AR(1); its half-life is \(\ln 2/\theta\) and its maximum-likelihood estimate is the AR(1) regression. The Euler shortcut underestimates the speed of reversion when \(\theta h\) is not small. In short samples the AR(1) coefficient is underestimated by about \((1+3b)/n\), and the half-life is systematically underestimated: with a true half-life of 40 days, the median estimate from one year of data is only 22 days, and a pure random walk shows a half-life of under 30 days nearly four times in ten. The next chapter asks how to test whether two prices have a mean-reverting combination: cointegration.
Scope of the numbers: This book presents mathematical models for teaching and research and is not investment, trading, tax or legal advice; leverage and derivatives can lose all of the money put in and more, and backtests and simulations do not represent future returns. Marked boxes separate published evidence, runnable Python calculations (16 programs, all checked), classical sources and the author's hypotheses.
Data table
The numbers below are printed verbatim by the chapter's Python program and can be reproduced by running it. standard-library Python onlyprinted values that match the answer: 30, 40
| HL | days | b | mean b_hat (theory) | median HL | HL < 0.7 x true | middle 95 % | |
| 10 | | 120 | 0.933 | 0.8997 (0.9014) | 7.1 | 48.6% | 3.0- 18.4 |
| 10 | | 250 | 0.933 | 0.9181 (0.9178) | 8.4 | 28.6% | 4.6- 16.8 |
| 10 | 1000 | 0.933 | | 0.9291 (0.9292) | 9.5 | 3.9% | 6.8- 13.2 |
| 40 | | 120 | 0.983 | 0.9429 (0.9499) | 14.0 | 81.1% | 4.0-120.1 |
| 40 | | 250 | 0.983 | 0.9650 (0.9670) | 22.0 | 65.5% | 7.7- 89.0 |
| 40 | 1000 | 0.983 | | 0.9787 (0.9789) | 34.0 | 28.7% | 18.5- 65.4 |
| random walk, 250 days | 37.9% of samples show a half-life under 30 days |
Key formula
Show the full program
# Small-sample bias of the AR(1)/OU estimate, mean estimated:
# E[b_hat] - b ~ -(1 + 3 b) / n (Marriott & Pope 1954; Kendall 1954).
import math, random
rng = random.Random(1954)
def ar1_hat(xs):
x, y = xs[:-1], xs[1:]; n = len(x)
mx, my = sum(x) / n, sum(y) / n
sxy = sum((p - mx) * (q - my) for p, q in zip(x, y))
return sxy / sum((p - mx) ** 2 for p in x)
def path(b, n):
xs = [rng.gauss(0, 1 / math.sqrt(1 - b * b)) if b < 1 else 0.0]
for _ in range(n): xs.append(b * xs[-1] + rng.gauss(0, 1))
return xs
print("HL | days | b | mean b_hat (theory) | median HL | HL < 0.7 x true"
" | middle 95 %")
for hl in (10, 40):
b = 0.5 ** (1 / hl)
for n in (120, 250, 1000):
bs = sorted(ar1_hat(path(b, n)) for _ in range(2000))
hls = sorted(math.log(2) / -math.log(x) if 0 < x < 1 else 1e9 for x in bs)
short = sum(h < 0.7 * hl for h in hls) / len(hls)
mb, th = sum(bs) / len(bs), b - (1 + 3 * b) / n
print(f"{hl:2d} | {n:4d} | {b:.3f} | {mb:.4f} ({th:.4f}) |"
f" {hls[1000]:6.1f} | {short:5.1%} |"
f" {hls[50]:5.1f}-{min(hls[1949], 999):5.1f}")
# A random walk (b = 1): how often does one year show a "half-life" under 30 days?
fake = [ar1_hat(path(1.0, 250)) for _ in range(2000)]
hl_fake = [math.log(2) / -math.log(x) for x in fake if 0 < x < 1]
print(f"random walk, 250 days: {sum(h < 30 for h in hl_fake) / len(fake):.1%} of samples"
f" show a half-life under 30 days")Single source and citation
Fan, Y. (2026). Liquidation Cascades, Order-Book Depth Depletion and Cointegrated Statistical Arbitrage (Version 1.0.0), Chapter 4: The Ornstein–Uhlenbeck Process: Mean Reversion and Its Estimation. 5D Library. https://doi.org/10.5281/zenodo.23796776
DOI: 10.5281/zenodo.23796776 · Read the monograph · 5DL-B-039 · v1.0.0 · CC-BY-NC-ND-4.0
BibTeX
@book{fan2026039,
author = {Fan, Yafu},
title = {Liquidation Cascades, Order-Book Depth Depletion and Cointegrated Statistical Arbitrage},
year = {2026},
publisher = {5D Library},
edition = {1.0.0},
doi = {10.5281/zenodo.23796776},
url = {https://doi.org/10.5281/zenodo.23796776}
}Other chapter answers in this book
- Chapter 1 · Order-Book Depth and Price Impact
- Chapter 2 · Perpetual Contracts, Funding and Forced Liquidation
- Chapter 3 · Liquidation Cascades, Branching Processes and Hawkes Self-Exciting Point Processes
- Chapter 5 · Cointegration, Pairs Trading and Broken Relationships
- Chapter 6 · The Kalman Filter and Dynamic Hedge Ratios
- Chapter 8 · Practice and a Pre-Registered Test