OPEN-SOURCE SCRIPT
Smart Range Projection

Smart Range Projection — Daily High/Low Forecast from Opening Volatility
OVERVIEW
This indicator projects the likely shape of the trading day early in the session, anchoring everything to the day's opening price. It plots the expected daily range envelope, an expansion range for potential trend day extension, and reversal zones near the projected extremes where
price often exhausts or turns.
The projection is built from a blend of four independent volatility inputs: daily ATR, opening volatility, CPR width, and an optional VIX multiplier. Once the opening window completes, the levels lock in for the rest of the session and do not shift.
HOW IT WORKS
1. Daily ATR Baseline
The previous day's confirmed ATR sets the expected full-day travel.
A user-defined multiplier (default 1.0x) converts this into the projected day range.
2. Opening Volatility Factor
The indicator measures the high-low range of the first N bars after the session opens (default 3 bars) and compares it to a rolling 20-day average of opening ranges. An unusually wide opening stretches the projection. An unusually narrow opening tightens it. The influence is
user-controlled (default 0.5).
3. CPR Width Lean
Central Pivot Range width is calculated from the previous day's high, low, and close. The current day's CPR width is compared to its 20-day average. A narrow CPR (relative to history) widens the projection because narrow CPRs statistically precede trending or expansion days.
A wide CPR tightens the projection.
4. VIX Multiplier (Optional)
An optional volatility-index input scales the entire projection based on the regime. Above the user-defined neutral level, the range widens.
Below it, the range tightens. Disabled by default. Enable only if your local volatility index is available on TradingView.
5. Reversal and Expansion Zones
- Projected High and Projected Low: the expected daily range envelope
- Expansion High and Low: dashed lines beyond the normal range, marking trend day extension targets
- Reversal Zones: shaded bands just inside the projected extremes where price often exhausts on normal days
- Expansion Zones: shaded bands between the normal envelope and expansion lines, highlighting trend day extension territory
NON-REPAINTING DESIGN
- Prior-day values use historical offset [1] with lookahead_off
- Day open is tracked locally via session change detection
- Projection levels lock once the opening window completes and remain fixed for the rest of the session
- No future data access, no lookahead leak
INPUTS
- Daily ATR length and base range multiplier
- Expansion multiplier and reversal zone percentage
- Opening window bars and volatility influence
- Optional VIX symbol, neutral level, and toggle
- CPR lean toggle, dashboard toggle, level rounding toggle
- Color customization for all elements
DASHBOARD
A status panel shows projected high and low, expansion high and low, day lean classification (Trend or Range bias from CPR width), measured opening volatility, and the active VIX multiplier.
ALERTS
Four alert conditions are available:
- Price reached projected day high
- Price reached projected day low
- Price hit expansion high (trend day extension)
- Price hit expansion low (trend day extension)
HOW TO USE
The projected high and low serve as the day's expected range boundaries.
Price reaching these zones early often coincides with exhaustion on range days. The expansion lines act as continuation targets when strong directional moves break the normal range envelope.
The day lean classification in the dashboard helps set expectations.
A Trend lean (narrow CPR) suggests price is more likely to reach the expansion lines. A Range lean (wide CPR) suggests price is more likely to oscillate within the normal envelope and reverse at the extremes.
This indicator works on intraday timeframes where multiple bars fit within a session. It is most effective on actively traded instruments with reliable opening sessions.
NOTES
This is a technical analysis tool intended for educational and informational purposes. Volatility projections are statistical estimates based on historical patterns and do not guarantee price will reach the projected levels. Always apply proper risk management and combine with
your own trading methodology.
CREDITS
Original implementation. Uses TradingView built-in ATR, security, and array functions combined with original opening volatility and CPR width lean methodology.
OVERVIEW
This indicator projects the likely shape of the trading day early in the session, anchoring everything to the day's opening price. It plots the expected daily range envelope, an expansion range for potential trend day extension, and reversal zones near the projected extremes where
price often exhausts or turns.
The projection is built from a blend of four independent volatility inputs: daily ATR, opening volatility, CPR width, and an optional VIX multiplier. Once the opening window completes, the levels lock in for the rest of the session and do not shift.
HOW IT WORKS
1. Daily ATR Baseline
The previous day's confirmed ATR sets the expected full-day travel.
A user-defined multiplier (default 1.0x) converts this into the projected day range.
2. Opening Volatility Factor
The indicator measures the high-low range of the first N bars after the session opens (default 3 bars) and compares it to a rolling 20-day average of opening ranges. An unusually wide opening stretches the projection. An unusually narrow opening tightens it. The influence is
user-controlled (default 0.5).
3. CPR Width Lean
Central Pivot Range width is calculated from the previous day's high, low, and close. The current day's CPR width is compared to its 20-day average. A narrow CPR (relative to history) widens the projection because narrow CPRs statistically precede trending or expansion days.
A wide CPR tightens the projection.
4. VIX Multiplier (Optional)
An optional volatility-index input scales the entire projection based on the regime. Above the user-defined neutral level, the range widens.
Below it, the range tightens. Disabled by default. Enable only if your local volatility index is available on TradingView.
5. Reversal and Expansion Zones
- Projected High and Projected Low: the expected daily range envelope
- Expansion High and Low: dashed lines beyond the normal range, marking trend day extension targets
- Reversal Zones: shaded bands just inside the projected extremes where price often exhausts on normal days
- Expansion Zones: shaded bands between the normal envelope and expansion lines, highlighting trend day extension territory
NON-REPAINTING DESIGN
- Prior-day values use historical offset [1] with lookahead_off
- Day open is tracked locally via session change detection
- Projection levels lock once the opening window completes and remain fixed for the rest of the session
- No future data access, no lookahead leak
INPUTS
- Daily ATR length and base range multiplier
- Expansion multiplier and reversal zone percentage
- Opening window bars and volatility influence
- Optional VIX symbol, neutral level, and toggle
- CPR lean toggle, dashboard toggle, level rounding toggle
- Color customization for all elements
DASHBOARD
A status panel shows projected high and low, expansion high and low, day lean classification (Trend or Range bias from CPR width), measured opening volatility, and the active VIX multiplier.
ALERTS
Four alert conditions are available:
- Price reached projected day high
- Price reached projected day low
- Price hit expansion high (trend day extension)
- Price hit expansion low (trend day extension)
HOW TO USE
The projected high and low serve as the day's expected range boundaries.
Price reaching these zones early often coincides with exhaustion on range days. The expansion lines act as continuation targets when strong directional moves break the normal range envelope.
The day lean classification in the dashboard helps set expectations.
A Trend lean (narrow CPR) suggests price is more likely to reach the expansion lines. A Range lean (wide CPR) suggests price is more likely to oscillate within the normal envelope and reverse at the extremes.
This indicator works on intraday timeframes where multiple bars fit within a session. It is most effective on actively traded instruments with reliable opening sessions.
NOTES
This is a technical analysis tool intended for educational and informational purposes. Volatility projections are statistical estimates based on historical patterns and do not guarantee price will reach the projected levels. Always apply proper risk management and combine with
your own trading methodology.
CREDITS
Original implementation. Uses TradingView built-in ATR, security, and array functions combined with original opening volatility and CPR width lean methodology.
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.