I have developed a robot that gets quite good results in back testing but not so much in live demo trading. My broker is Pepperstone and for backtesting I used TrueFX tick data (directly provided by Pepperstone’s main liqudity provider Integral) that I converted to 1-minute data using a script. I am assuming that the data quality is good enough to produce realistic results.
However, in live demo trading via a VPS the robot does not do as many trades as in back testing, it does approx. 5 trades a day as opposed to approx. 25 a day in backtesting.
Run it for a few days span on the LIVE Demo account. Then set up the Strategy Tester to run for the same span of days and see which trades the LIVE demo performed and which ones they didn’t.
I’m not an expert on the tick data feeds, but I suspect that there are some differences in how you set up the data for your backtesting and how the robot responds to the data in the LIVE DEMO account.
Are you using a 1 minute time frame for your ROBOT? I assume if you are getting 25 trades a day in your back testing, you have written a robot to do “scalping”. The robot on the LIVE DEMO may not respond as quickly to changing conditions.
You can also check out another post I just did about doing back testing and things to look at in Post #4 in this thread:
The main problem with MT4 data is that it is not “tick-by-tick” data. It is “second-by-second”.
There can be many ticks per second.
Backtests on higher time frames generally are more accurate. Scalping bots - give very different(bad) results.
You can download real tick data for mt4 which gives much more realistic results.
Live accounts differ greatly between dealers. The number of ticks you receive is very important for robots. Some brokers give many more ticks then others. The more ticks = better signals.
Some brokers average the ticks. This generally gives a lot less trades with robots.
Also remember with mt4 the broker can play with tick frequency and averaging as easily as they can play with spread and price, etc. Most ppl do not realize tick frequency is very important.
In addition to the comments above, check your Experts tab to make sure there are no trade execution errors. There are a number of order gotchas in MT4 that cause errors to trigger and orders not to fill.
Also, make sure your code’s trade actions are well commented using Print statements. Before a trade is about to be transmitted you could make a comment like:
Print("Placing Buy order @" + Ask);
This way if there are fill errors you will be alerted.
Also, make sure to trap errors in your trade execution by handling return values correctly and reporting errors with Print statements so you can fix the code.
That is not correct. Strategy Tester and other software uses the 1M historical broker data unless special efforts are made to obtain tick data. By interpolating the 1M data, it makes it look like tick data is being used.
Yes and just to add, if an EA makes assumptions about the order in which the high or low of the bar occur, this can cause spurious signals in backtesting that don’t materialize in live or forward testing.
Even if you technically made everything right, there’s always a huge profit difference between a backtest and real trading when you back tested the same price data that you used for strategy development or optimization. Of course the backtest then shows huge profits. For a realistic test, you’ll need “out of sample” price data that was not used for selecting or optimizing your strategy.