OPEN-SOURCE SCRIPT

Recent Swing High/Low Lines With Stats Table

28
Swing-Based Volatility

This indicator measures volatility using the distance between recent swing highs and swing lows rather than fixed averages like ATR. Each swing captures a meaningful shift in market control, making this a structure-aware view of volatility.

The tool calculates and plots the average swing range over time, highlighting when the market is expanding (wide swings, high volatility) or contracting (tight swings, low volatility). These phases can help traders identify breakout potential, adjust stop-loss or profit targets, and align position sizing with current market conditions.

Disclaimer

The information and publications are not meant to be, and do not constitute, financial, investment, trading, or other types of advice or recommendations supplied or endorsed by TradingView. Read more in the Terms of Use.