Tried and proven strategy - can it be EA’d?
-
Watched numerous videos now and this strategy keeps cropping up. I was wondering if anybody has been able to replicate this in the form of an EA? Or how this would be done?
Essentially ensuring price is above/below 9, 13 and 21 EMA on M5 chart. Once the price touches the 9 EMA, a buy/sell range is set based off of the highest high and lowest low on the last 5 candles. Whilst also being above/below the 9 and 21 EMA on the H1.
Any ideas or experience with this?
Thanks,
-
@thefaunt Hi!
Trading the trend with moving averages is literally the oldest trick in the book. Nobody profits from it, especially on small timeframes.
You must be more clever than that, and I can guarantee you that you will not find anything but total BS from youtube. Its just to get views.
When scalping, you dont want to follow the trend - small timeframes very rarely have a continous trend and most of the time your sl will get hit.I don't mean to be overly harsh or unfriendly, its just the reality of this business

Anyway I made the EA just for the giggles: https://fxdreema.com/shared/AUYaS0NWb
Its in mql5.
I used mas 8, 13, 21 (all fibo numbers)
Open buy order when last candle low is between ma 8 and 13
Open sell order when last candle high is between ma 8 and 13
Entry at the 5-bar extreme, stop-loss at the opposite 5-bar extreme, take-profit 200% of SL.
Result?
A straight line down the drain:

-
Someone might wonder, what if I used ma9 instead of ma8?
What if I used different expiration for the order?
What if I used different percentage for my TP?
What if I used different lookback period than 5 candles?Here's all those scenarios, and all possible combinations of those scenarios:

-
Genetic optimization backtest of 10496 combinations will take some time, I'll let it run on EURUSD 2018-2020.
Edit: It found one profitable combination. $5 net profit with $260 drawdown

-
@roar thanks for you efforts roar - it’s really appreciated. I’m new to this whole EA creation, so I’m in the process of learning fxdreema to create what I want, and also how to test it properly on MT5.
How did you do the optimisation? As currently I’m creating a new EA for each variable I want to modify and running the tests each time; which seems a lot more time consuming than what you’re doing!
Thanks again
-
@thefaunt said in Tried and proven strategy - can it be EA’d?:
@roar thanks for you efforts roar - it’s really appreciated. I’m new to this whole EA creation, so I’m in the process of learning fxdreema to create what I want, and also how to test it properly on MT5.
How did you do the optimisation? As currently I’m creating a new EA for each variable I want to modify and running the tests each time; which seems a lot more time consuming than what you’re doing!
Thanks again
Its no problem, I like to practise building systems.
To start optimizing, just set up the strategy tester for a normal backtest, and finally select Optimization: genetic algorithm.
Then go to your inputs-tab to set the optimized parameters and their ranges, just like I show a couple posts above.

-
I know this is old but I thought I would add seeing that I also just tried to create an EA for this strategy. Here's the link to the rules - SIMPLE and PROFITABLE Forex Scalping Strategy!
I just worked on the Buy leg to see if I could get it working. Also worked on the 15min chart, referencing the 1H, etc.
I have been working on this for nearly 10 days now, changing as much as I can to try and make a profit - failed every time. I tested it on 1 month, 3 months, 6 months, different pairs, different pip levels...
I would literally make more money doing the complete opposite every time...
-
@roar Out of interest how did you reach that genetic based algorithm option? Is it an MT5 thing? I'm using MT4 and don't have the option it seems but I also don't know what that even means so it's probably for the best

-
@zereleth its mt5 here, but mt4 has the option hidden in "Expert properties" if I remember correctly...
Genetic algorithm is a "smart" way to do the optimization, it learns to skip some probably bad input combinations to speed up the process.
-
@roar Ah thanks thats really helpful, I found it and gave it a try in MT4 but it only seemed to run it once


Any idea why that might be?
-
@zereleth you have to set your desired input ranges in the Expert properties.
For example, moving average could have start=3 step=5 stop=100,
and then mt4 will calculate results on ma periods 3, 8, 13, 18, ... 98, 100.