backtest results differ when I put a Print statement. please help!

To add comments, please log in or register
abbasakh
15
abbasakh  

Hi All,

I wrote a simple EA and back tested it and it game a loss. I tried to debug the EA by putting the good old Print statement. when I ran the EA again on the same currency and same period, the results turned to profit! just simple print, compile and then back test again and the whole result is different now.

it is very frustrating as i have spend couple of months testing and now i doubt everything I have done.

anyone knows this phenomena and why it happens ? any help would be appreciated.


Regards

Catalin Zachiu
32882
Catalin Zachiu  
abbasakh:

If you use spread setting "Current" in the tester  may give you different results if you didn't change any of the other trading conditions or if you use some parameter from the "Print" .

abbasakh
15
abbasakh  
Catalin Zachiu:

If you use spread setting "Current" in the tester  may give you different results if you didn't change any of the other trading conditions or if you use some parameter from the "Print" .

I just noticed that I was calling a function that returns a true/false within the Print function. it's like "Print(IsSignalLong());" within IsSignalLong() I was using Chande's momentum indicator to check cross over 0. when I use any other indicator withing this function, the results are consistent. I believe the issue is with the coding of the indicator . I am using fixed spread in the tester.
To add comments, please log in or register