OPEN-SOURCE SCRIPT
Colidation Breakout Structure(HA-CBS)

Overview
Most breakout indicators suffer from "noise," reacting to every minor price movement and producing frequent fakeouts. HA-CBS solves this by utilizing Heikin-Ashi (HA) smoothing and Swing Point analysis to isolate periods of extreme energy accumulation (Consolidation) and verifying the subsequent breakout with Fair Value Gaps (FVG).
⚠️ Usage Note: This script is strictly optimized for Heikin-Ashi charts. The core logic relies on Heikin-Ashi body (Open/Close) calculations. To ensure the signals align perfectly with the price action you see, please switch your chart type to Heikin-Ashi.
How it Works: The HA-CBS Logic
Unlike generic indicators that draw signals instantly, HA-CBS follows a rigorous three-step verification process to ensure market displacement is real:
Key Features
Trading Strategy
Most breakout indicators suffer from "noise," reacting to every minor price movement and producing frequent fakeouts. HA-CBS solves this by utilizing Heikin-Ashi (HA) smoothing and Swing Point analysis to isolate periods of extreme energy accumulation (Consolidation) and verifying the subsequent breakout with Fair Value Gaps (FVG).
⚠️ Usage Note: This script is strictly optimized for Heikin-Ashi charts. The core logic relies on Heikin-Ashi body (Open/Close) calculations. To ensure the signals align perfectly with the price action you see, please switch your chart type to Heikin-Ashi.
How it Works: The HA-CBS Logic
Unlike generic indicators that draw signals instantly, HA-CBS follows a rigorous three-step verification process to ensure market displacement is real:
- Structural Mapping: Using a multi-term swing point algorithm, the script identifies key supply and demand boundaries.
- Consolidation Counting (The "Coil"): The script measures how many consecutive Heikin-Ashi bodies remain "tucked" within the structural range. A built-in CANDLE_MARGIN_RATE ensures that insignificant doji-like candles don't disrupt the count. The longer the "coil," the higher the potential for an explosive breakout.
- Kinetic Validation (FVG): When price finally breaks the structural boundary, the script checks for a Fair Value Gap. An FVG-backed breakout confirms that institutional "Impulse" is present, distinguishing a genuine trend start from a mere stop-run.
Key Features
- Impulse Filter: Filters out low-momentum movements by requiring an FVG at the moment of the structural break.
- HA-Body Precision: Focuses on the "core" of the candle, ignoring volatile wicks that often lead to false signals.
- Multi-Term Flexibility: Users can toggle between Short, Intermediate, and Long-term swing structures to suit scalping, day trading, or swing trading.
- Recent Candidate Mode: Use the Recent Only toggle to keep your chart clean by only displaying the most recent and relevant breakout candidate for each structure.
Trading Strategy
- Strategy A: The Impulse Entry (Aggressive)
Enter the trade as soon as the HA-CBS signal is confirmed (HA Close breaks the structure with an FVG). This captures the immediate momentum as a new supply/demand imbalance is established. - Strategy B: The Mitigation Entry (Conservative)
Wait for price to return (retrace) to the identified HA-CBS Block. Institutional players often "mitigate" their positions by returning to the breakout source. This approach typically offers a higher Risk/Reward ratio.
Open-source script
In true TradingView spirit, the creator of this script has made it open-source, so that traders can review and verify its functionality. Kudos to the author! While you can use it for free, remember that republishing the code is subject to our House Rules.
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.
Open-source script
In true TradingView spirit, the creator of this script has made it open-source, so that traders can review and verify its functionality. Kudos to the author! While you can use it for free, remember that republishing the code is subject to our House Rules.
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.