EA on strategy tester vs live forward testing

 
Hi, why would an EA appear to work well in strategy tester in that the EA logic works but fails on forward testing by not following the intended logic?  Anybody have an idea. 
 
Maybe there is a bug in your code.
 
Either that or you are fall into curve fitting. I have tried the same EA with back test, optimize it and back test, everything is fine. But the moment I do a forward test..back to the drawing board
 
Daniel Sam:
Either that or you are fall into curve fitting. I have tried the same EA with back test, optimize it and back test, everything is fine. But the moment I do a forward test..back to the drawing board

HI Daniel, please explain curve fitting simply to a non-programmer. 

 
Marco vd Heijden:
Maybe there is a bug in your code.

There may well be a bug in the code but surely that will also affect backtesting?

 
Forexmadesimple:

HI Daniel, please explain curve fitting simply to a non-programmer. 

Take a look at this article

https://www.automatedtrading.com/2014/05/08/curve-fitting/
 

Hello,

I think, we must test an EA to know how exactly it work, before buy it. The strategy that used by the EA can effects the performance in live trading, like most scalping method that need fast execution and low spread pair, we need a VPS to run for such EA .. But some EA that using higher TP/ SL that reflected the strategy, like swing trading, will give not much different between back test and live trading result.. I'm sorry if my opinion is not make any sense with logic matter, but in matter how an EA work and back test and forward test/live trading result, i think it's a good view..

 

How to combine stoploss condition in Ea.

for example. I want to close as stoploss if -30 pip and H>2hour since entry point.

thank you

 
Forexmadesimple:

HI Daniel, please explain curve fitting simply to a non-programmer. 

Lets assume you are an athlete . 
You are training for an event (a mountain running event) on a specific location (a similar terrain) with a specific start and end point.

Training ,is you getting familiar with generalized non specific aspects of mountain running  such as how to handle your balance your energy
,pacing yourself and all things that occur automatically in your mind and body (adjusting posture to slope ,pressure on muscles etc).

Overfitting means you learn that in 100 meters the slope goes up 30degrees ,then you turn left after 50 meters ,you pace down at 300 meters 
theres a big rock at 400 meters .(you learn how to make a perfect lap on the training terrain if that makes sense)

Forward testing , is the Actual event and the terrain is similar but not exactly the same as the training ground so ,in simple terms , you expect 
the slope to be 30 degrees at 100 meters but theres a puddle of water .ploop.Something like that.