Well, I've recently been getting into forex, and I don't think I understand anything yet. This is just something I'm curious to post to see what people have to say.
Disclaimer: Not my code. I only made minor changes.
Ummmm, I was having trouble understanding contract sizes;
I believe I've set it so there is a 100:50 pip reward:risk ratio. (2:1!)
With a 0.5 lot size USD base.
Another thing I want to note, backtesting this from 2017-2018ish, it's generated lost profits. Starting around 2018, this strategy began to generate profits. 2019 appeared to generate significantly larger profits.
Another Disclaimer: I may not know what I'm saying this entire post. (: I don't advise to use this strategy.
Strategy Idea:
4h Chart, EURUSD pair.
21 SMA crosses 40 SMA, buy or sell depending on crossover or crossunder.
Risk(Stop-Loss) 50 pips, Target(Take-Profit) 100 pips.
Or close entry if opposing entry appears.
Simple yet interesting. (in my eyes)