PROTECTED SOURCE SCRIPT
zavaUnni-Consolidation Zone Detector

Consolidation Zone Detector - Explanation
This Pine Script indicator is designed to detect Consolidation (flat/sideways) zones in price movement by analyzing volatility and identifying periods of consolidation. It visually highlights these flat zones, helping traders spot potential breakout opportunities.
🔹 Key Features
Customizable Timeframe Selection
Users can choose a specific timeframe (TF) for analysis.
Option to use Heikin Ashi candles instead of standard candlesticks for smoother trend detection.
Volatility-Based Analysis
Calculates body size (co_rate) and high-low range (hl_rate) to measure price movement.
If volatility is below a predefined threshold, the zone is classified as flat.
Flat Zone Detection & Visualization
Detects periods of low volatility and marks them as flat zones.
Stores the highest (flat_high) and lowest (flat_low) prices during the flat period.
If volatility increases beyond the threshold, the flat status is deactivated.
Visual Representation with Lines & Shaded Areas
When a flat zone is detected, it is highlighted with orange lines at the high and low levels.
These lines extend dynamically as the flat zone continues.
A semi-transparent shaded area is drawn to emphasize the consolidation range.
🔹 How to Use
Identify sideways price movements and prepare for potential breakouts.
Use in conjunction with other indicators to refine entry and exit points.
Combine with Heikin Ashi candles for a smoother trend analysis.
This indicator is particularly useful for spotting range-bound markets and detecting areas of low volatility where a breakout may soon occur
This Pine Script indicator is designed to detect Consolidation (flat/sideways) zones in price movement by analyzing volatility and identifying periods of consolidation. It visually highlights these flat zones, helping traders spot potential breakout opportunities.
🔹 Key Features
Customizable Timeframe Selection
Users can choose a specific timeframe (TF) for analysis.
Option to use Heikin Ashi candles instead of standard candlesticks for smoother trend detection.
Volatility-Based Analysis
Calculates body size (co_rate) and high-low range (hl_rate) to measure price movement.
If volatility is below a predefined threshold, the zone is classified as flat.
Flat Zone Detection & Visualization
Detects periods of low volatility and marks them as flat zones.
Stores the highest (flat_high) and lowest (flat_low) prices during the flat period.
If volatility increases beyond the threshold, the flat status is deactivated.
Visual Representation with Lines & Shaded Areas
When a flat zone is detected, it is highlighted with orange lines at the high and low levels.
These lines extend dynamically as the flat zone continues.
A semi-transparent shaded area is drawn to emphasize the consolidation range.
🔹 How to Use
Identify sideways price movements and prepare for potential breakouts.
Use in conjunction with other indicators to refine entry and exit points.
Combine with Heikin Ashi candles for a smoother trend analysis.
This indicator is particularly useful for spotting range-bound markets and detecting areas of low volatility where a breakout may soon occur
受保護腳本
此腳本以閉源形式發佈。 不過,您可以自由且不受任何限制地使用它 — 在此處了解更多資訊。
免責聲明
這些資訊和出版物並不意味著也不構成TradingView提供或認可的金融、投資、交易或其他類型的意見或建議。請在使用條款閱讀更多資訊。
受保護腳本
此腳本以閉源形式發佈。 不過,您可以自由且不受任何限制地使用它 — 在此處了解更多資訊。
免責聲明
這些資訊和出版物並不意味著也不構成TradingView提供或認可的金融、投資、交易或其他類型的意見或建議。請在使用條款閱讀更多資訊。