DasanC

Bandpass Filter v2

Attempts to detect trends based on detrended cycles, instead of momentum or price action!

If you enable bar painting, then uptrends will be painted in lime green, then dark green to signify the cycle is ending.
Downtrends will be painted in bright red, then maroon to signify the cycle is ending.

Reducing fast limit will allow the indicator to respond much faster to cycle changes, but may cause more weak signals.
Increasing slow limit will "hold on to" cycles for a longer time & allow trends to extend through small periods of consolidation.

Tweak these settings to your style of trading!

Good settings for scalping:
14, 35

Good settings for intraday:
30, 60
40, 80

Good settings for swing trades:
20, 200 (gets into trade earlier)
50, 120

Ultimately, you'll have to decide the best limits for each security.

Cheers,
DasanC


Need Indicators/Strategies for TradingView? -> t.me/pinescripters_jobs
General questions about Pinescript? -> t.me/pinescripters
Protected script
This script is published closed-source but you may use it freely. You can favorite it to use it on a chart. You cannot view or modify its source code.
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.

Want to use this script on a chart?