OPEN-SOURCE SCRIPT

LPB MicroCycles Strategy

3419
What it is:

We use the Hodrick-Prescott filter applied to the closing price, and then take the outputted trendline and apply a custom vwap, the time frame of which is based on user input, not the default 1 day vwap . Then we go long if the value 2 bars ago is greater then one bar ago. We sell and color the bars and lines when the if the value of 2 bars ago is less than one bar ago.

Also included:
GUI for backtesting
ATR Based Stop Loss

How to use:
Go long when the indicators suggest it, and use the stop losses to reduce risk.


Best if paired with a volatility measurement (inside candles, average true range , bollingerband%B)

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.