pb-algo

Dual Bollinger Band Mean Reversion

Simple but solid mean reversion indicator with sl and tp levels. Most of the code is based on the built in bollinger bands script. Designed for scalping 1-5 minute timeframes.

The indicator consists of two sets of bollinger bands.

Price has to close below the lower (fast) bollinger band, above the moving average of the (slower) bollinger band.
If price now closes above the lower (fast) bb, the indicator draws a label at the open of the next candle (which would be a potential entry point). Take profit becomes the upper bollinger band, stop loss the same distance below the open of the candle.

I've built in a simple backtesting function that calculates the potential win/loss-ratio. Loss and profit levels are 1:1. Exit strategy could be improved on.

Adjusting the lengths depending on the asset proves to be a good idea.

The slower bollinger bands can help to identify ranging markets and/or trends following regular bollinger bands theory.

Feel free to comment with any changes that you'd like to be made.



Script open-source

Nello spirito di condivisione promosso da TradingView, l'autore (al quale vanno i nostri ringraziamenti) ha deciso di pubblicare questo script in modalità open-source, così che chiunque possa comprenderlo e testarlo. Puoi utilizzarlo gratuitamente, ma il riutilizzo del codice è subordinato al rispetto del Regolamento. Per aggiungerlo al grafico, mettilo tra i preferiti.

Declinazione di responsabilità

Le informazioni ed i contenuti pubblicati non costituiscono in alcun modo una sollecitazione ad investire o ad operare nei mercati finanziari. Non sono inoltre fornite o supportate da TradingView. Maggiori dettagli nelle Condizioni d'uso.

Vuoi usare questo script sui tuoi grafici?