lisaforex wrote:This is similar to error described at this post here https://forexsb.com/forum/topic/9887/is … ed-errors/, but I believe it isn't a setting based solution as mentioned in the previous post.
I generated a basic random strategy on the H1 timeframe for the USDJPY. Equity chart looks good. No issues there. However, I find alot of the times, I cannot replicate EA Studio Backtest report in MT5. Backtesting on MT4 works fine, but in MT5, I get a bunch of 'Market Closed' errors. Upon further investigation into the individual trades within EA studio itself, 51/53 trades are entering at 0:00 which is causing the error. Really? That is highly unlikely considering I'm looking at a multi year strategy where the entry logic is simple: "Enter when the bar opens below after opening above it".
This is not the first time I have seen this error. I get it many times on many different currency pairs.
Hey,
Lots of traders get confused about trading right at midnight server time (00:00). It's super important to understand this, especially when you're developing your trading strategies. This is especially true if you use EA Studio (which uses "fake", fixed spreads) or MT5 (which uses real, changing spreads).
The "Market Closed" errors you see in MT5 at 00:00 are because of how the "spread" (the difference between the buy and sell price) acts when the Asian market opens.
Here's the main point: EA Studio, when it uses fixed spreads that stay the same, doesn't show you what really happens to the spread at 00:00. In real trading, the spread always gets much bigger exactly at midnight server time. This is because the big banks in America stop trading for the day, and the banks in Asia take over. The spread can jump up to be way bigger than normal – sometimes even 30 times bigger!
Because EA Studio uses fixed spreads, it only sees the price movement. At 00:00, it looks like there are good trading chances when the price jumps up or down quickly. EA Studio might create trading strategies that try to use these spikes at 00:00, thinking it can trade with the normal spread and monetize them.
But in real trading (and in MT5 if it's set up right), it's not like that. At 00:00, the spread is actually HUGE. It's not a good time to trade. When MT5 tries to do these trades based on real market conditions with real spreads, it correctly says "Market Closed" because the spread is too big. Brokers stop trades from happening then to protect you from bad trades during these crazy spread times, usually just for a few minutes (you can verify this if right clicking on any symbol in MT5 and check the trading session times).
So, if you create trading strategies in EA Studio based on these "nice spikes" at 00:00 (using fixed spreads), they look like awesome tradable opportunities on paper, but they will fail in real trading. They are trying to use something that isn't really there in the way EA Studio shows it. This is just a problem with testing using fixed spreads.
An easy way to fix this and get better realistic results is to just ignore the midnight server time hour in your trading settings in EA Studio. The spread goes back to normal about an hour after the Asian market opens, around 1:00 server time. Just set your trading session times to "01:00 - 23:59" and it will solve this problem.