indicator · own pane · open source
Volatility Ratio
Running…
Loading chart…
About
Volatility Ratio divides a short-window ATR by a long-window ATR — a clean number for 'are we in a quiet regime or a loud one right now'.
- Above 1.0 = recent ATR is bigger than the longer-term baseline (vol expansion).
- Below 1.0 = compression / squeeze regime; expect a breakout soon.
Source code
//@version=5
indicator("Volatility Ratio", overlay=false)
shortLen = input.int(5, "Short ATR length", minval=1, maxval=100)
longLen = input.int(20, "Long ATR length", minval=2, maxval=200)
vr = ta.atr(shortLen) / ta.atr(longLen)
hline(1, "Parity", color=color.gray)
p_VR = plot(vr, "VR", color=color.purple, linewidth=2)
No comments yet.
Sign in to comment.