Strategy Tester

 
Hi! One question: I am testing this EA with strategy tester, I test using open prices, and on 1Hr I get positive results. Then I test again on 4Hr and I get negative results. And I change again to 1Hr and I get negative results. I am using always same dates for testing, same currency, all I am modifying is the timeframe. Any ideas?  
 
Daniel Cioca: Hi! One question: I am testing this EA with strategy tester, I test using open prices, and on 1Hr I get positive results. Then I test again on 4Hr and I get negative results. And I change again to 1Hr and I get negative results. I am using always same dates for testing, same currency, all I am modifying id the time frame. Any ideas?  

Change your spread to a fixed value instead of relying on "current" which can change from one test to another. Also check your EA code for possible logic bugs.

Forum on trading, automated trading systems and testing trading strategies

Tester results are not matching optimization results

Fernando Carreiro, 2022.04.25 11:06

That is usually due to the EA code having bugs, especially in regards to the proper handling of the initialisation and de-initialisation process of the EA (e.g. proper initialisation and handling of global variables).

Another important point is to always use a fixed spread value and not use the "current" spread value, so that spread does not change between optimisation passes.

 

 
Fernando Carreiro #:

Change your spread to a fixed value instead of relying on "current" which can change from one test to another. Also check your EA code for possible logic bugs.

Thanks! I’ll try that… 
Reason: