Rolling Liquidity Clusters Channel [LuxAlgo]The Rolling Liquidity Clusters Channel indicator identifies dynamic support and resistance zones by calculating levels that maximize candle wick touches while strictly avoiding intersections with candle bodies within a rolling window. This tool provides a unique perspective on liquidity clusters, highlighting price levels where historical rejection is most concentrated without being invalidated by price "closing" through them.
🔶 USAGE
The indicator plots a channel consisting of an Upper Level, a Lower Level, and a Mid Level. The space between these levels is filled with a vertical gradient to visually represent the strength of the liquidity zone.
Upper Level (Red): Represents a resistance zone where the most upper wicks are concentrated without any candle body in the lookback window crossing above it.
Lower Level (Green): Represents a support zone where the most lower wicks are concentrated without any candle body in the lookback window crossing below it.
Mid Level (Orange): Represents the equilibrium or average of the current liquidity channel.
Traders can use these levels to identify potential reversal points or areas of price consolidation. A breakout from the channel might indicate a shift in market structure as price moves beyond the most inclusive "non-broken" wick levels.
🔶 DETAILS
The script employs a specific constraint logic to ensure the levels represent true "untouched" liquidity:
🔹 Body-Crossing Constraint
Before identifying the wick touches, the script calculates the highest candle body high and lowest candle body low within the user-defined window. The resulting levels are guaranteed to stay outside of this "body zone," ensuring that the plotted levels represent prices that the market reached but failed to sustain via a close.
🔹 Maximizing Touches
To find the most significant level, the algorithm searches for the most inclusive price point. For the upper level, it identifies the lowest "high" that remains above all candle bodies. For the lower level, it identifies the highest "low" that remains below all candle bodies. This mathematical approach effectively finds the level where the most price action "clusters" via wicks.
🔹 Vertical Gradient Fills
The visual style uses a vertical gradient fill. The upper half fades from 90% transparency at the Upper Level (Red) to 100% transparency at the Mid Level. The lower half follows a similar logic, fading from the Lower Level (Green) toward the center. This creates a "glow" effect, emphasizing the outer boundaries where liquidity is highest.
🔶 SETTINGS
Window Size: The number of bars used for the rolling calculation. A larger window creates more stable, long-term levels, while a smaller window adapts quickly to recent price action.
Upper Level: Customize the color of the upper resistance level and its associated gradient fill.
Lower Level: Customize the color of the lower support level and its associated gradient fill.
Mid Level: Customize the color of the central equilibrium line.
Pine Script® indicator










