by Support_AdrianS » Thu May 05, 2011 10:20 am
Dear Kevin,
You are right. It is indeed a problem, but only when testing on Dukascopy historical data with the MT4 platform.
The Spread in MT4 version of our expert advisor is calculated by the formula:
Spread = MarketInfo(Symbol(),MODE_SPREAD);
In forward test, when the program runs in real conditions, the spread is calculated correctly.
In back tests on MT4 platform the spread is also calculated correctly, because historical data do not include historical data for spreads and the test is done with the spread of the testing time.
On our java version of the robot for Dukascopy, the spread is calculated by the formula:
Spread = Ask – Bid;
We make all the back tests and optimizations directly on Dukascopy with our java version of the robot and because the spread is calculated as the difference between Ask and Bid the tests are performed correctly and the problem that you mentioned does not appear.
We will add to the MT4 version of our expert advisor an additional condition in order to properly test the robot on Dukascopy historical data on MT4 platform also.
This addition will be available at the next update, hopefully this month.
Thank you for having discovered this problem and we hope that you will continue this research.
Kind regards,
ForexRealProfitEA Team.