OPEN-SOURCE SCRIPT
[ReForge] Trend Indicator

🔷 [ReForge] Trend Indicator – Hybrid Volatility Regime Framework
The ReForge Trend Indicator is a closed-source adaptive regime model designed to identify structural trend transitions using a hybrid volatility boundary and state-based persistence logic.
It is not a moving average crossover, ATR trail, or derivative of a standard trailing indicator. The core engine is a blended volatility regime framework that combines absolute and relative distance modelling, band memory mechanics, confirmation validation, and structural participation filters into a unified system.
🔹 Core Regime Construction
The trend boundary is derived from a hybrid volatility calculation:
• A smoothed absolute volatility component (True Range or High–Low)
• A relative percent-of-price volatility component
• A blended “Hybrid” mode averaging both representations
The percent-of-price component allows the boundary to scale naturally across instruments with different price magnitudes (e.g., crypto vs metals), while the absolute component preserves structural stability.
This blended distance is multiplied by a configurable factor and applied above and below price to form dynamic regime bands.
🔹 Band Memory & Regime Persistence
Unlike freely recalculating envelopes, the bands use state-based persistence:
• In a bullish regime, the lower boundary can only rise.
• In a bearish regime, the upper boundary can only fall.
A regime transition occurs only when price decisively breaches the active boundary and optional confirmation bars validate persistence.
This prevents oscillation and reduces regime noise during compression phases.
🔹 Multi-Layer Validation Architecture
The regime engine can optionally require alignment across several structural conditions before signals are issued.
These include:
• Volatility expansion threshold (Bollinger width used as a volatility state measurement)
• Higher timeframe alignment (computed using the same internal regime logic)
• Regression slope direction (measured as percent change per bar over a configurable window)
• Directional volume slope validation (see below)
These elements are not independent bundled indicators; they are contextual state filters applied to the core regime model to validate structural conditions before entries are confirmed.
🔹 Directional Volume Modelling
Volume is decomposed into directional components based on candle structure.
Linear regression slopes of bullish and bearish volume flows are compared to determine whether participation supports price direction.
Trend-quality dots reflect this internal participation model.
Signals may optionally be gated or delayed (“arming”) until directional participation aligns with the regime.
This differs from simple volume averaging or threshold filters.
🔹 Continuation Structure
After a confirmed regime transition, the system can wait for a structural pullback to the active boundary and require a reclaim condition before issuing continuation entries.
This pullback-reclaim logic is tied directly to the regime boundary rather than to a moving average or oscillator signal.
🔹 Exit Architecture
Exit models are modular and structurally independent from the entry logic. These include:
• Regime boundary violation with ATR buffer
• Anchored VWAP reclaim failure (VWAP anchored at regime transition)
• Volatility contraction after expansion
• Volume divergence at structural extremes
• MACD structural momentum break
• Opposite regime transition
RSI and MACD calculations are used as internal momentum state conditions within this framework, not as standalone signal generators.
Each exit module can be enabled or disabled independently.
🔹 Mode & Adaptation
Aggressive, Balanced and Strict modes adjust:
• Volatility multiplier
• Confirmation persistence
• Expansion thresholds
Auto profile dynamically adapts core parameters based on timeframe and instrument type.
🔹 Structural Distinction
This framework differs materially from:
• Fixed ATR-multiple trails
• Static moving-average systems
• Single-factor volatility envelopes
Its distinguishing elements include:
• Blended absolute/relative volatility modelling
• State-persistent band memory
• Confirmation-bar regime validation
• Regression-based slope gating
• Directional volume slope modelling
• Pullback-reclaim continuation logic
• Modular structural exit architecture
These components operate as an integrated regime framework rather than as discrete indicator overlays.
🔹 Closed-Source Disclosure
This script is published as closed-source because its hybrid volatility blending, state-persistent regime logic, and directional volume regression modelling form a composite framework developed specifically for expansion-phase regime trading.
The ReForge Trend Indicator is a closed-source adaptive regime model designed to identify structural trend transitions using a hybrid volatility boundary and state-based persistence logic.
It is not a moving average crossover, ATR trail, or derivative of a standard trailing indicator. The core engine is a blended volatility regime framework that combines absolute and relative distance modelling, band memory mechanics, confirmation validation, and structural participation filters into a unified system.
🔹 Core Regime Construction
The trend boundary is derived from a hybrid volatility calculation:
• A smoothed absolute volatility component (True Range or High–Low)
• A relative percent-of-price volatility component
• A blended “Hybrid” mode averaging both representations
The percent-of-price component allows the boundary to scale naturally across instruments with different price magnitudes (e.g., crypto vs metals), while the absolute component preserves structural stability.
This blended distance is multiplied by a configurable factor and applied above and below price to form dynamic regime bands.
🔹 Band Memory & Regime Persistence
Unlike freely recalculating envelopes, the bands use state-based persistence:
• In a bullish regime, the lower boundary can only rise.
• In a bearish regime, the upper boundary can only fall.
A regime transition occurs only when price decisively breaches the active boundary and optional confirmation bars validate persistence.
This prevents oscillation and reduces regime noise during compression phases.
🔹 Multi-Layer Validation Architecture
The regime engine can optionally require alignment across several structural conditions before signals are issued.
These include:
• Volatility expansion threshold (Bollinger width used as a volatility state measurement)
• Higher timeframe alignment (computed using the same internal regime logic)
• Regression slope direction (measured as percent change per bar over a configurable window)
• Directional volume slope validation (see below)
These elements are not independent bundled indicators; they are contextual state filters applied to the core regime model to validate structural conditions before entries are confirmed.
🔹 Directional Volume Modelling
Volume is decomposed into directional components based on candle structure.
Linear regression slopes of bullish and bearish volume flows are compared to determine whether participation supports price direction.
Trend-quality dots reflect this internal participation model.
Signals may optionally be gated or delayed (“arming”) until directional participation aligns with the regime.
This differs from simple volume averaging or threshold filters.
🔹 Continuation Structure
After a confirmed regime transition, the system can wait for a structural pullback to the active boundary and require a reclaim condition before issuing continuation entries.
This pullback-reclaim logic is tied directly to the regime boundary rather than to a moving average or oscillator signal.
🔹 Exit Architecture
Exit models are modular and structurally independent from the entry logic. These include:
• Regime boundary violation with ATR buffer
• Anchored VWAP reclaim failure (VWAP anchored at regime transition)
• Volatility contraction after expansion
• Volume divergence at structural extremes
• MACD structural momentum break
• Opposite regime transition
RSI and MACD calculations are used as internal momentum state conditions within this framework, not as standalone signal generators.
Each exit module can be enabled or disabled independently.
🔹 Mode & Adaptation
Aggressive, Balanced and Strict modes adjust:
• Volatility multiplier
• Confirmation persistence
• Expansion thresholds
Auto profile dynamically adapts core parameters based on timeframe and instrument type.
🔹 Structural Distinction
This framework differs materially from:
• Fixed ATR-multiple trails
• Static moving-average systems
• Single-factor volatility envelopes
Its distinguishing elements include:
• Blended absolute/relative volatility modelling
• State-persistent band memory
• Confirmation-bar regime validation
• Regression-based slope gating
• Directional volume slope modelling
• Pullback-reclaim continuation logic
• Modular structural exit architecture
These components operate as an integrated regime framework rather than as discrete indicator overlays.
🔹 Closed-Source Disclosure
This script is published as closed-source because its hybrid volatility blending, state-persistent regime logic, and directional volume regression modelling form a composite framework developed specifically for expansion-phase regime trading.
Script de código aberto
Em verdadeiro espírito do TradingView, o criador deste script o tornou de código aberto, para que os traders possam revisar e verificar sua funcionalidade. Parabéns ao autor! Embora você possa usá-lo gratuitamente, lembre-se de que a republicação do código está sujeita às nossas Regras da Casa.
Aviso legal
As informações e publicações não se destinam a ser, e não constituem, conselhos ou recomendações financeiras, de investimento, comerciais ou de outro tipo fornecidos ou endossados pela TradingView. Leia mais nos Termos de Uso.
Script de código aberto
Em verdadeiro espírito do TradingView, o criador deste script o tornou de código aberto, para que os traders possam revisar e verificar sua funcionalidade. Parabéns ao autor! Embora você possa usá-lo gratuitamente, lembre-se de que a republicação do código está sujeita às nossas Regras da Casa.
Aviso legal
As informações e publicações não se destinam a ser, e não constituem, conselhos ou recomendações financeiras, de investimento, comerciais ou de outro tipo fornecidos ou endossados pela TradingView. Leia mais nos Termos de Uso.