First of all let me tell you that I am pretty new to coding and I read a lot of stuff and spent a lot of time before asking this question... This forum really helps a lot, thanks to all contributors.
I have written an EA that is more like a scalper. I say "like" because it's not exactly a scalper. So on average it opens 5-6 trades daily (per pair) and closes on a profit level when reached. It works with 4 different indicators (rsi, atr, etc.). Anyway, these are not really important as the problem, I guess, is not related to these.
So what happens: I launch MT4 and load the EA to the chart and turn on trading, within the first 24 hours or so, it opens all orders it needs to open (I check it with strategy tester later in the day and the orders that I see on tester were also all opened and closed in real time as well, so all in blotter even at exactly same price as tester suggests). However after some time (usually after that initial 24 hours) the EA starts opening noticeably less trades. I run the EA on 20 different pairs so normally I have around 90-100 traders per day and this number drops to 40-50 after that first 24 hours. When I run it in the tester for that time frame, I also see that some trades that are opened in tester were not opened (in real time) at all. EA is not stuck as it does open some of the trades it should open... I don't see any errors in the logs as well.
I believe the code is not the problem, as sometimes it works perfectly and opens all trades as they should be opened. Is there anyone who can suggest a solution or at least a way to track down what's going on?
Many thanks in advance...
To add comments, please log in or register