OPEN-SOURCE SCRIPT
Volatility Radar - Muti-Timeframe [PUCHON]

Volatility Radar — MTF [PUCHON]
Reads ATR%, Historical Volatility (HV%), and Bollinger Band Width (BBW%) across 5 timeframes simultaneously. Classifies each timeframe into a volatility regime — LOW / NORMAL / HIGH / EXTREME — using percentile rank computed independently per timeframe. A single consensus row summarises all 5 timeframes into one actionable signal.
Open-source script — full code visible in Pine Script editor.
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
WHAT MAKES IT DIFFERENT
Most volatility tools work on a single timeframe. This dashboard:
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
HOW TO READ EACH ROW
Row 1 — ATR %
Average True Range as a percentage of price. Answers: "How large are the candles right now, relative to price?"
Row 2 — HV %
Historical Volatility (annualized). Standard deviation of log returns × √252.
Row 3 — BBW %
Bollinger Band Width = (Upper BB − Lower BB) / Midline × 100.
Row 4 — REGIME
Percentile rank of current ATR% against the last Regime Lookback bars of that same timeframe.
Regime is relative to the instrument's own history. 0.5% ATR could be LOW on a volatile crypto but EXTREME on a blue-chip stock. The percentile rank adapts automatically.
Row 5 — ATR▐ (Sparkline)
Unicode bar █ (filled) / ░ (empty) — each TF's ATR% as a proportion of the highest ATR% across all columns.
Row 6 — SIGNAL
Consensus across all 5 timeframes. Counts TFs in HIGH or EXTREME regime.
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
CANDLE & BACKGROUND COLORING
Candles and background tint reflect the current chart timeframe's regime:
A glow label above the last candle shows the current regime at a glance.
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
PRACTICAL SCENARIOS
Scenario A — Safe to trade
All TFs: NORMAL or LOW → SIGNAL: STABLE
Action: Use momentum strategies. ATR% bars are short and roughly equal.
Scenario B — Reduce size
5m: NORMAL | 15m: HIGH | 60m: EXTREME | 240m: HIGH | D: NORMAL → SIGNAL: ELEVATED
Action: Widen stop to accommodate 60m ATR range. Reduce position by 30–50%.
The 60m sparkline bar will be the longest — confirming where volatility is concentrated.
Scenario C — Stand aside
ALL TFs: EXTREME → SIGNAL: ⚠ RISK OFF
Action: Wait for regime to cool to NORMAL before re-entering. Occurs during major news events, flash crashes, or market opens.
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
HOW TO USE
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
SETTINGS GUIDE
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
ALERTS
Five built-in alert conditions:
Set via: Right-click chart → Add alert → Condition: Volatility Dashboard — MTF
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
LIMITATIONS
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
OPEN SOURCE
Published under Mozilla Public License 2.0.
Free to use, modify, and build upon.
If you publish a modified version, credit to the original script is appreciated.
⚠ Disclaimer: This script is for educational and informational purposes only. It does not constitute financial advice. Volatility analysis does not guarantee profitable trades. Past volatility patterns do not predict future price movements. Always conduct your own analysis and apply proper risk management before trading.
Reads ATR%, Historical Volatility (HV%), and Bollinger Band Width (BBW%) across 5 timeframes simultaneously. Classifies each timeframe into a volatility regime — LOW / NORMAL / HIGH / EXTREME — using percentile rank computed independently per timeframe. A single consensus row summarises all 5 timeframes into one actionable signal.
Open-source script — full code visible in Pine Script editor.
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
WHAT MAKES IT DIFFERENT
Most volatility tools work on a single timeframe. This dashboard:
- Runs three independent metrics per timeframe via bundled request.security() — one call per TF, no redundant data fetching
- Classifies regime using ta.percentrank() computed inside each TF's own bar history — "HIGH" on 5m and "HIGH" on Daily are both statistically meaningful relative to that TF's own past
- Renders a unicode sparkline row █░ to compare relative ATR across all timeframes at a glance
- Neon Dark styling: regime label pinned to last candle, colored regime badges, candle coloring, background state tint
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
HOW TO READ EACH ROW
Row 1 — ATR %
Average True Range as a percentage of price. Answers: "How large are the candles right now, relative to price?"
- Higher ATR% = bigger candles, wider spreads, larger stop loss needed
- Compare across TFs: if 5m ATR% suddenly equals the 60m ATR%, intraday volatility has spiked unexpectedly
- Color reflects regime: Neon Green = Low Cyan = Normal Red = High Magenta = Extreme
Row 2 — HV %
Historical Volatility (annualized). Standard deviation of log returns × √252.
- Answers: "At what annualized rate is this asset moving right now?"
- Rising HV = market accelerating. Falling HV = compressing toward a squeeze
- Cross-TF: if 5m HV is 3% but Daily HV is 37%, short-term is calm inside a long-term volatile environment — mean-reversion setup signal
- Displayed in neutral Cyan — informational, not regime-colored
Row 3 — BBW %
Bollinger Band Width = (Upper BB − Lower BB) / Midline × 100.
- Low BBW = bands squeezing → breakout risk rising
- High BBW = bands expanded → trend or momentum is active
- BBW spike after a Low regime = early breakout confirmation
- Multiple TFs showing Low BBW simultaneously = convergent squeeze — watch closely
Row 4 — REGIME
Percentile rank of current ATR% against the last Regime Lookback bars of that same timeframe.
- LOW — below 25th percentile → unusually quiet; possible accumulation or squeeze
- NORMAL — 25th–75th percentile → average conditions; trend-following works well
- HIGH — 75th–90th percentile → elevated; widen stops, reduce position size
- EXTREME — above 90th percentile → rare spike; consider standing aside
Regime is relative to the instrument's own history. 0.5% ATR could be LOW on a volatile crypto but EXTREME on a blue-chip stock. The percentile rank adapts automatically.
Row 5 — ATR▐ (Sparkline)
Unicode bar █ (filled) / ░ (empty) — each TF's ATR% as a proportion of the highest ATR% across all columns.
- Longest bar = most volatile timeframe right now
- Normal: bars grow left (5m) to right (Daily) — higher TFs are naturally more volatile in absolute terms
- Warning: a short-TF bar suddenly matching a long-TF bar → intraday volatility spike
- Bar color matches the regime of that column
Row 6 — SIGNAL
Consensus across all 5 timeframes. Counts TFs in HIGH or EXTREME regime.
- STABLE — NORMAL VOLATILITY → 0–1 TFs elevated. Trade normally.
- ELEVATED ACROSS TIMEFRAMES → 2–3 TFs elevated. Widen stops, reduce size.
- ⚠ RISK OFF — EXTREME VOLATILITY → 4–5 TFs elevated. Consider standing aside.
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
CANDLE & BACKGROUND COLORING
Candles and background tint reflect the current chart timeframe's regime:
- 🟢 LOW — calm market, potential accumulation zone
- 🔵 NORMAL — standard conditions, trend strategies work well
- 🔴 HIGH — elevated, tighten stops and reduce size
- 🟣 EXTREME — dangerous conditions, reduce or close exposure
A glow label above the last candle shows the current regime at a glance.
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
PRACTICAL SCENARIOS
Scenario A — Safe to trade
All TFs: NORMAL or LOW → SIGNAL: STABLE
Action: Use momentum strategies. ATR% bars are short and roughly equal.
Scenario B — Reduce size
5m: NORMAL | 15m: HIGH | 60m: EXTREME | 240m: HIGH | D: NORMAL → SIGNAL: ELEVATED
Action: Widen stop to accommodate 60m ATR range. Reduce position by 30–50%.
The 60m sparkline bar will be the longest — confirming where volatility is concentrated.
Scenario C — Stand aside
ALL TFs: EXTREME → SIGNAL: ⚠ RISK OFF
Action: Wait for regime to cool to NORMAL before re-entering. Occurs during major news events, flash crashes, or market opens.
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
HOW TO USE
- Add to any chart as an overlay — works on all instruments and timeframes
- Set your 5 analysis timeframes in the Timeframes settings group
- Check REGIME row — identify which timeframes are elevated
- Check SIGNAL row — use as your position sizing guide
- Read sparkline bar row — longest bar = where volatility is concentrated
- Enable candle coloring and background tint for instant visual scanning
- Set alert on Regime Escalation to be notified when volatility rises
- Set alert on Regime Cooling to re-enter after a volatility spike
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
SETTINGS GUIDE
- TF 1–5 — Five analysis timeframes (default: 5 / 15 / 60 / 240 / Daily)
- ATR Length (default: 14) — ATR period. 14 is standard; increase for smoother values on noisy instruments
- HV Length (default: 20) — Log-return standard deviation lookback for HV%
- BBW Length (default: 20) — Bollinger Band period for width calculation
- Regime Lookback (default: 100) — Percentile rank window per TF. Higher = more stable labels, slower to react. Lower = faster but noisier
- Color Candles by Regime — Toggle neon candle coloring on/off
- Background Tint — Toggle near-invisible regime background tint
- ATR% Sparkline Row — Toggle unicode bar chart row visibility
- Table Position — Move dashboard to any of the four chart corners
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
ALERTS
Five built-in alert conditions:
- Extreme Volatility — current TF enters EXTREME regime
- High+ Volatility — current TF enters HIGH or EXTREME regime
- Low Volatility — current TF enters LOW regime (watch for squeeze)
- Regime Escalation — volatility rises from Normal to High/Extreme
- Regime Cooling — volatility falls back from High/Extreme to Normal
Set via: Right-click chart → Add alert → Condition: Volatility Dashboard — MTF
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
LIMITATIONS
- Regime needs at least Regime Lookback confirmed bars on each TF. First bars on very high timeframes may show "—" until enough history is loaded
- HV uses √252 annualization (trading days). Crypto 24/7 markets are slightly understated — actual annualized vol is ~17% higher than displayed
- Does not predict direction. HIGH and EXTREME regimes occur in both strong trends and sharp crashes. Use with a directional indicator
- Requesting a TF lower than the chart's own TF has no effect — Pine Script cannot look inside the current bar
- Current (unconfirmed) bar values update in real time and may differ from the final bar-close value. This is normal behavior, not repainting
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
OPEN SOURCE
Published under Mozilla Public License 2.0.
Free to use, modify, and build upon.
If you publish a modified version, credit to the original script is appreciated.
⚠ Disclaimer: This script is for educational and informational purposes only. It does not constitute financial advice. Volatility analysis does not guarantee profitable trades. Past volatility patterns do not predict future price movements. Always conduct your own analysis and apply proper risk management before trading.
Script open-source
Dans l'esprit TradingView, le créateur de ce script l'a rendu open source afin que les traders puissent examiner et vérifier ses fonctionnalités. Bravo à l'auteur! Bien que vous puissiez l'utiliser gratuitement, n'oubliez pas que la republication du code est soumise à nos Règles.
Clause de non-responsabilité
Les informations et publications ne sont pas destinées à être, et ne constituent pas, des conseils ou recommandations financiers, d'investissement, de trading ou autres fournis ou approuvés par TradingView. Pour en savoir plus, consultez les Conditions d'utilisation.
Script open-source
Dans l'esprit TradingView, le créateur de ce script l'a rendu open source afin que les traders puissent examiner et vérifier ses fonctionnalités. Bravo à l'auteur! Bien que vous puissiez l'utiliser gratuitement, n'oubliez pas que la republication du code est soumise à nos Règles.
Clause de non-responsabilité
Les informations et publications ne sont pas destinées à être, et ne constituent pas, des conseils ou recommandations financiers, d'investissement, de trading ou autres fournis ou approuvés par TradingView. Pour en savoir plus, consultez les Conditions d'utilisation.