OPEN-SOURCE SCRIPT
ATR > VXN Alert (5m)

ATR > VXN Volatility Divergence Indicator
This custom TradingView indicator monitors real-time volatility divergence between realized volatility (via Average True Range, ATR) and implied volatility (via the CBOE NASDAQ Volatility Index, VXN). It is inspired by the GJR-GARCH (Glosten-Jagannathan-Runkle Generalized Autoregressive Conditional Heteroskedasticity) model, which captures asymmetric volatility dynamics—particularly how markets respond more sharply to negative shocks than to positive ones.
Core Logic:
Chart on NQ (5 minute timeframe)
ATR (5-min) reflects realized intraday volatility of the Nasdaq 100 futures (NQ).
VXN (5-min, delayed) represents forward-looking implied volatility.
The indicator highlights regime shifts in volatility:
ATR < VXN: Volatility compression → potential energy building up (market coiling).
ATR > VXN: Volatility expansion → real movement exceeds expectations → potential breakout zone.
Visuals & Alerts:
Background turns green when ATR crosses above VXN, signaling a bullish expansion regime.
Background turns red when ATR drops below VXN, signaling compression or risk-off environment.
Custom alerts trigger on volatility regime shifts for breakout traders.
Application (Manual GJR-GARCH Strategy):
Similar to how the GJR-GARCH model captures volatility clustering and asymmetry, this indicator identifies when actual price volatility (ATR) begins to spike beyond implied forecasts (VXN), often after periods of contraction—mirroring a conditional variance shock in the GARCH framework.
Traders can align with directional bias using technical confluence (order flow, structure breaks, liquidity zones) once expansion is confirmed.
This custom TradingView indicator monitors real-time volatility divergence between realized volatility (via Average True Range, ATR) and implied volatility (via the CBOE NASDAQ Volatility Index, VXN). It is inspired by the GJR-GARCH (Glosten-Jagannathan-Runkle Generalized Autoregressive Conditional Heteroskedasticity) model, which captures asymmetric volatility dynamics—particularly how markets respond more sharply to negative shocks than to positive ones.
Core Logic:
Chart on NQ (5 minute timeframe)
ATR (5-min) reflects realized intraday volatility of the Nasdaq 100 futures (NQ).
VXN (5-min, delayed) represents forward-looking implied volatility.
The indicator highlights regime shifts in volatility:
ATR < VXN: Volatility compression → potential energy building up (market coiling).
ATR > VXN: Volatility expansion → real movement exceeds expectations → potential breakout zone.
Visuals & Alerts:
Background turns green when ATR crosses above VXN, signaling a bullish expansion regime.
Background turns red when ATR drops below VXN, signaling compression or risk-off environment.
Custom alerts trigger on volatility regime shifts for breakout traders.
Application (Manual GJR-GARCH Strategy):
Similar to how the GJR-GARCH model captures volatility clustering and asymmetry, this indicator identifies when actual price volatility (ATR) begins to spike beyond implied forecasts (VXN), often after periods of contraction—mirroring a conditional variance shock in the GARCH framework.
Traders can align with directional bias using technical confluence (order flow, structure breaks, liquidity zones) once expansion is confirmed.
開源腳本
本著TradingView的真正精神,此腳本的創建者將其開源,以便交易者可以查看和驗證其功能。向作者致敬!雖然您可以免費使用它,但請記住,重新發佈程式碼必須遵守我們的網站規則。
免責聲明
這些資訊和出版物並不意味著也不構成TradingView提供或認可的金融、投資、交易或其他類型的意見或建議。請在使用條款閱讀更多資訊。
開源腳本
本著TradingView的真正精神,此腳本的創建者將其開源,以便交易者可以查看和驗證其功能。向作者致敬!雖然您可以免費使用它,但請記住,重新發佈程式碼必須遵守我們的網站規則。
免責聲明
這些資訊和出版物並不意味著也不構成TradingView提供或認可的金融、投資、交易或其他類型的意見或建議。請在使用條款閱讀更多資訊。