Dual Ehlers Decycler & Dynamic Cycle BandpassOverview
Traditional moving averages are plagued by lag, and standard oscillators force you to split your attention across multiple chart panes. This indicator solves both problems by combining John Ehlers’ Decycler mathematics with advanced Pine Script v6 polyline rendering, allowing you to visualize true market cycles and momentum shifts directly on your main price chart without distorting the scale.
This is not just a moving average crossover tool; it is a complete signal processing suite designed to extract the dominant market cycle while rejecting high-frequency noise and low-frequency macro trends.
Core Features
Dual Ehlers Decyclers (Zero-Lag Profiling): Utilizes the Ehlers Decycler algorithm to track price with near-zero lag. By inputting the specific dominant cycle lengths (e.g., from a cycle forecaster), the fast and slow decyclers perfectly bracket your target market wave.
True Bandpass Filter Oscillator: By subtracting the slow decycler from the fast decycler (Dec1 - Dec2), the script isolates the pure cyclical resonance between the two lengths. This acts as a Bandpass filter—stripping out erratic price spikes (noise) and the underlying macro trend to reveal the pure sine wave of the current market cycle.
Derivative Momentum Coloring: The decycler lines do not just change color based on simple slope. The script calculates the Velocity (1st derivative) and Curvature (2nd derivative) of the trend. The lines only light up brightly when momentum and acceleration are aligned, keeping you out of choppy, decelerating markets.
ATR-Normalized Hysteresis Cloud: The fill between the two decyclers utilizes an ATR-based noise filter. Instead of flickering wildly when price chops around the decycler lines, the cloud state requires a true volatility-adjusted breakout to shift bullish or bearish.
How to Trade With It
Cycle Crossovers (The Zero-Cross): When the fast decycler crosses the slow decycler, the Bandpass Oscillator perfectly crosses the zero line. This signals a phase shift in the market's dominant cycle .
Amplitude Analysis: Watch the height of the dynamic polyline oscillator. A crossover that occurs after a massive oscillator peak suggests a powerful exhaustion and reversal. A crossover while the oscillator is flat near the zero line suggests a weak, choppy market—stay out.
Visual Divergence: Because the oscillator is plotted on the same pane as price, spotting divergence is incredibly intuitive. If price makes a higher high, but the dynamic yellow polyline makes a lower high, the cycle is running out of gas before the decyclers even cross.
Customization
Input your own dominant cycle lengths based on your preferred timeframe or external cycle forecasters.
Adjust the visible amplitude of the dynamic oscillator (default 50% of price height) to fit your visual preference.
Toggle signals, clouds, and overlays on or off for a cleaner view.
Credit to John Ehlers for the foundational Decycler mathematics.
Pine Script® indicator















