// PAPER 01 — VOLATILITY KINEMATICS
Deviation over Deviation (DoD)
A second-order stochastic metric for volatility regime detection.
The Z-score of the standard deviation of standard deviation. DoD isolates the volatility of volatility — flagging explosive expansion and extreme compression before they manifest in price space.
// the volatility of volatility
A rolling Z-score of second-order dispersion. The surface below renders the deviation field in three dimensions — ridges are regime expansion, valleys are compression, and the storm front is where DoD fires first.
Abstract
Standard financial volatility metrics — such as Average True Range (ATR), Bollinger Band Width, and the CBOE Volatility Index (VIX) — measure the level or magnitude of price dispersion, but consistently fail to signal structural volatility regime transitions before they manifest in price space. This paper introduces Deviation over Deviation (DoD), a second-order quantitative framework that calculates the rolling Z-score of the standard deviation of standard deviation. By isolating the higher-order kinematics of volatility (the "volatility of volatility"), DoD identifies both explosive volatility expansion phases and extreme volatility compression regimes. We define the mathematical formulation of DoD, implement a production-grade Pine Script v6 algorithm featuring multi-timeframe evaluation and multi-source flex inputs (including custom VoVix estimators), compare its statistical properties against traditional metrics, and detail its application across dynamic position sizing, tail-risk management, and algorithmic regime filtering.01Introduction — The Volatility-of-Volatility Imperative
Traditional quantitative finance models often treat volatility as a static or slowly evolving background parameter. However, empirical financial time series exhibit pronounced non-stationarity, variance drift, and volatility clustering (Engle, 1982; Mandelbrot, 1963). In real-time trading operations, the primary source of catastrophic tail-risk is not high volatility per se, but unannounced transitions between volatility regimes.
Conventional indicators suffer from inherent structural flaws:
- Lagging magnitude metrics (ATR, Historical Volatility) measure historical price dispersion over N bars. By the time ATR expands during a volatility spike, the move is often near completion.
- Fixed parametric bounds (Bollinger Bands) rely on baseline standard deviations around a moving average, making them vulnerable to sustained trending environments where bands remain artificially expanded without indicating whether the regime is accelerating or decaying.
02Mathematical Architecture
Let xt represent a discrete time-series variable at bar t.
2.1 — First-Order Volatility σt
Standard dispersion — the magnitude of the deviation, exactly as ATR and historical volatility report it.
2.2 — Second-Order Volatility DoDt
The same operator, applied to volatility itself. Where σ measures the level of dispersion, DoD measures the kinematics — how fast dispersion is itself dispersing.
2.3 — Normalized Regime Metric Zt
A Z-score makes the second-order state scale-free and comparable across assets, timeframes, and sources. Epsilon prevents division by a flat volatility field.
03Comparative Performance Analysis
| Metric | Detects regime shifts? | Normalized? | Multi-source? | Complexity |
|---|---|---|---|---|
| ATR (14) | No | No | No | O(N) |
| Bollinger %B | No | Yes | No | O(N) |
| CBOE VIX | Yes | Yes | No | O(N) |
| DoD (DAFE) | Yes | Yes | Yes | O(N+M) |
// Live laboratory — the DoD storm front
● LIVE
A synthetic regime engine drives the trace below. σ (green) is computed over N bars; DoD (cyan) over M. The Z-score (white, lower panel) fires through its bands exactly when a regime transition is underway — before the magnitude metrics have moved. Drag the sliders and watch the storm front change character.
04Live Evidence
Production output from the DAFE DoD indicator on TrendSpider — regime bands, Z-score trace, and multi-timeframe evaluation in a live market. The indicator and its full parameter surface ship on the store listing. Chart screenshot forthcoming.
05Applications
- Dynamic position sizing — scale risk down as Z climbs into expansion, and size up in confirmed compression (mean-reversion environments).
- Tail-risk management — extreme positive Z marks the volatility storm front; extreme negative Z marks the compression spring that precedes violent expansion.
- Algorithmic regime filtering — gate trend vs. mean-reversion strategy families on Z sign and magnitude, on any timeframe, from any source series (close, range, VIX, custom VoVix estimators).
06Production Implementation — Pine Script v6
The reference implementation ships as a single self-contained indicator, with the two lookbacks, both thresholds, and full multi-source flex inputs exposed. A custom VoVix estimator can be substituted for the built-in σ channel, making DoD a generic second-order operator rather than a close-only metric.
//@version=6 indicator("Deviation over Deviation (DoD)", overlay=false, max_bars_back=500) devLen = input.int(18, "Deviation Lookback (N)") dodLen = input.int(19, "DoD Lookback (M)") zThreshHi = input.float(2.2, "High DoD Z-Score Threshold") zThreshLo = input.float(-1.9, "Low DoD Z-Score Threshold") src = close dev = ta.stdev(src, devLen) dev_sma = ta.sma(dev, dodLen) dev_of_dev = ta.stdev(dev, dodLen) dod_z = dev_of_dev != 0 ? (dev - dev_sma) / dev_of_dev : 0.0 plot(dod_z, color=color.yellow, linewidth=2, title="DoD Z-Score") hline(0, color=color.gray) hline(zThreshHi, color=color.red) hline(zThreshLo, color=color.green)
07Limitations & Assumptions
- DoD is a second-order regime metric — it detects transitions, not direction. It must be paired with a directional strategy family.
- Both lookbacks assume stationarity within the window; extremely long N can blend regimes together.
- The Z-score distribution is not strictly Gaussian; thresholds are empirical, not probabilistic.
08Conclusion
DoD answers a question the first-order metrics cannot ask: is volatility itself accelerating or decaying? By normalizing second-order dispersion into a Z-score, it produces a scale-free, asset-agnostic, source-agnostic regime readout — and it fires before price space confirms the transition. The framework is open, the math is disclosed, and the live implementation is on the store.
// NEXT FRAMEWORK
From volatility kinematics to phase space.
TED-PE reconstructs price momentum in four dimensions — velocity, acceleration, jerk, snap — and learns which geometry matters, live.