vitelot

MA cross strategy Vts

vitelot Uppdaterad   
The simple Moving average cross strategy is here implemented.
I guess there are multitudes of similar scripts around.
I post this one since I was asked by some friends, and I'll let it free to use for anybody.
Here you can choose the year where to start backtesting, the source, the type of MA, the SL and TP multiplicators of ATR, for which you can also choose the averaging period.
Feel free to modify this script. I would be grateful if you could preserve the first lines of comments including my user names.
The MA cross strategies can be very effective, especially when used on the daily TF.
Try for example the combo EMA15-EMA30 SL=1.5ATR TP=1ATR on EURCHF daily to get an impressive 83% win ratio.
Or EMA20-EMA81 on the GBPCHF to get an 87%.
In those cases where EMA does not perform well, try to set a less lagging MA, like the Hull MA.
I hope you like this script so that you could push the like button multiple (odd) times and you start following me.
I've got a bunch of other interesting scripts to share.
Comments and suggestions are welcome.
Versionsinformation:
1) added Tenkan lines
2) no need to treat JPY differently
Versionsinformation:
// March 2019:
// nr of traded lots adjusted according to SL and risk
// cleaner trade management, avoid superposed trades
// added ema200 filter: if active long possible only when ema200 is increasing
// short only if it decreases
// cleaner code
Skript med en öppen källkod

I sann TradingView-anda har författaren publicerat detta skript med öppen källkod så att andra handlare kan förstå och verifiera det. Hatten av för författaren! Du kan använda det gratis men återanvändning av den här koden i en publikation regleras av våra ordningsregler. Du kan ange den som favorit för att använda den i ett diagram.

Frånsägelse av ansvar

Informationen och publikationerna är inte avsedda att vara, och utgör inte heller finansiella, investerings-, handels- eller andra typer av råd eller rekommendationer som tillhandahålls eller stöds av TradingView. Läs mer i Användarvillkoren.

Vill du använda det här skriptet i ett diagram?