OPEN-SOURCE SCRIPT
已更新 Ehlers Dominant Cycle Stochastic RSI v2

Ehlers Dominant Cycle Stochastic RSI
Summary
An adaptive Stochastic RSI whose lengths are set by the market's measured dominant cycle rather than by a fixed input. The indicator continuously estimates the dominant cycle period in price and feeds that period directly into the RSI and Stochastic calculations, so the oscillator's lookback adjusts as the underlying cycle shortens or lengthens across symbols and timeframes.
The Inspiration — John Ehlers
The indicator is built on the digital signal processing work of John Ehlers, who treated price as a waveform and applied engineering filters to extract its underlying cycle. Rather than rely on a single cycle estimate, it runs three independent measurement methods in parallel:
Before measurement, price is conditioned with Ehlers' filter set: a Super Smoother filter, a Highpass filter to remove the trend (DC) component, and an optional Bandpass "spectral dilation" pre-filter to isolate the cycle band. The three estimates are then cross-checked. When they agree, their values are blended into a single confirmed period; when they diverge, outliers are down-weighted before the result is smoothed.
Features
Summary
An adaptive Stochastic RSI whose lengths are set by the market's measured dominant cycle rather than by a fixed input. The indicator continuously estimates the dominant cycle period in price and feeds that period directly into the RSI and Stochastic calculations, so the oscillator's lookback adjusts as the underlying cycle shortens or lengthens across symbols and timeframes.
The Inspiration — John Ehlers
The indicator is built on the digital signal processing work of John Ehlers, who treated price as a waveform and applied engineering filters to extract its underlying cycle. Rather than rely on a single cycle estimate, it runs three independent measurement methods in parallel:
- Hilbert Transform homodyne discriminator — Ehlers' classic dominant-cycle estimator
- Autocorrelation Periodogram — Pearson correlation across lags to identify the repeating period
- Goertzel / DFT power spectrum — a frequency-domain scan for the strongest cycle
Before measurement, price is conditioned with Ehlers' filter set: a Super Smoother filter, a Highpass filter to remove the trend (DC) component, and an optional Bandpass "spectral dilation" pre-filter to isolate the cycle band. The three estimates are then cross-checked. When they agree, their values are blended into a single confirmed period; when they diverge, outliers are down-weighted before the result is smoothed.
Features
- Triple cycle detection with confirmation — Hilbert, Autocorrelation, and DFT run together, with a 0–100% confidence score reflecting how closely they agree
- Confidence-weighted period blending — each method is weighted by agreement and correlation strength, then smoothed into one cycle period
- Adaptive RSI & Stochastic lengths — both derive from the detected cycle, with independent multipliers (e.g. 0.5× for half-cycle, 1.0× for full-cycle)
- Spectral dilation pre-filter — optional bandpass with adjustable bandwidth for tighter cycle isolation
- Momentum histogram — normalized K−D centered on the midline, with bars that fade as momentum stalls
- OB/OS zone shading
- Performance controls — recalc interval and DFT window settings to manage the spectral scans
發行說明
Performance Mode added Users can now select one single cycle detection method (Hilbert, Autocorrelation, or DFT) rather than having all three running together.
This new mode will help if you're having issues with the indicator loading or want to select a specific cycle method.
開源腳本
秉持TradingView一貫精神,這個腳本的創作者將其設為開源,以便交易者檢視並驗證其功能。向作者致敬!您可以免費使用此腳本,但請注意,重新發佈代碼需遵守我們的社群規範。
discord.gg/REapC6SGtz
b3artrades@gmail.com
b3artrades@gmail.com
免責聲明
這些資訊和出版物並非旨在提供,也不構成TradingView提供或認可的任何形式的財務、投資、交易或其他類型的建議或推薦。請閱讀使用條款以了解更多資訊。
開源腳本
秉持TradingView一貫精神,這個腳本的創作者將其設為開源,以便交易者檢視並驗證其功能。向作者致敬!您可以免費使用此腳本,但請注意,重新發佈代碼需遵守我們的社群規範。
discord.gg/REapC6SGtz
b3artrades@gmail.com
b3artrades@gmail.com
免責聲明
這些資訊和出版物並非旨在提供,也不構成TradingView提供或認可的任何形式的財務、投資、交易或其他類型的建議或推薦。請閱讀使用條款以了解更多資訊。