BackTesting different from live trading
-
Hi, i have being able to build a successful EA, makes more than 15% of profit per month but this is only back testing results. when it went live, its like a different EA. rather than making money i have lost money.
why do backtesting results differ from the live trading records ?
this isnt something specific to Fxdreema based EA's, but also other EA's on the market.
they simply do not behave similary as on backtesting. which is really oddnote: spread and latency are always modified on the backtesting to make it more realistic.
now that i have seen the post made by @fxdreema on the poor countries poor people i realized that there could be more to this, altough, i really hope it wasnt an empty dream since three important things was put into this whole project, my time, effort and money.
-
It's normal that backtest result is unlike live one, in particular, MT4. MT5 may be better.
Simply because backtest is not live
-
@ZakTrading Some quick tips:
- NEVER trust any backtest with a quality tick data below 99%. Even 98% is simply crap.
- Backtest usually sucksbecause it's based on fixed spread values (not on MT5, though). That will break any reliable results.
- Past performances NEVER guarantee future results.
-
-
@ZakTrading hey mate, if the spread affects the EA's bottom line, adjusting your EA's strategy to a higher timeframe may be an option. I'd recommend anything above H1, like H4 D1 is where neither of spread nor news have any impact on your strategy or PnL for most of the instruments.
-
Kindly see this inf indi to assess the costs (aka spreads) of the business based on the spread to ATR relation for each specific TF you trade on:
AT-Spreads.ex4 -
Any indicator's calculation result in green text should be ok to run an EA on the respective TF.
-
Also, check the indi descrip here: link text

-
-
- @ZakTrading it also makes sense to add a "Spread filter" block to filter out unprofitable (premium zone) entries that could be triggered because of the broker's spread was too high the moment your entry occurred
- Feel free to adjust that according to your preferences based on what spread is acceptable for your strat and instr


-
-
@ZakTrading also you can review to protect your SL with what I call "Conditional SL"
-
In the nutshell, you may want to set an additional rule for SL based on the candle close rather than just a price reaching a fixed SL price level
-
Example: your SL is 30 pips (or relative ATR %) and you operate on the 5 min TF. You can set a rule that your SL is triggered only in case if price CLOSE on M5 behind your SL price level.
-
This can make your SL more rigid to broker's spread-widening (during high impact news, holidays or Asian session) and MM Stop-hunt manipulations. You can see this as a reliable spike protection
-
However, this approach to an SL has its pros and cons. In case of a high volatility, this may incur relatively bigger loses if price eventually close behind your SL comparison to a fixed SL
-
-
When there is low liquidity, any trade you open will move against you, rendering the parameters you adjusted in the backtesting useless. The problem is that the backtesting data is historical and is not affected by your trading activity when there is low liquidity.
In addition to that, we have the issue of the spread, internet latency problem, the problem of fundamentals, and the problem of misadjustment of the bot. I would say that the bot needs to be adjusted daily, or even more frequently, as each market requires a different adjustment.
-
@ZakTrading If you think that a bot is only useful for trading automatically, you are missing out on a lot. With FxDreema, you can create windows with data, buttons to open and close orders, order grids, modify stops, and much more.
-
@GeoFX thanks for you inputs !
i am using spread filters, that's why i backtest with spread modification to make sure it is working.
thanks for the TF advices, you make some really good points.
-
@Alan-paredes2 my strategy was consistently making profits on the monthly net profit level in backtesting.
its not an issue of strategy, its unlikely, when i went live with it the bot was running on a VPS. latency less than 15ms. same parameters.i was trading the GOLD. it made profits, but the net result was negative, meaning i lost.
the sole purpose of making EA's was to automatically make and manage trades.
-
@ZakTrading I'm glad that you don't need advice and that things are going well for you. Regarding the issue of negative results in backtesting, please check if they are occurring when the database runs out of data, meaning when the examination is ending. It tends to close all open trades, and if there happen to be losing trades, it will deduct them from the balance. That's why, if you see a significant drop in the backtesting graph at the end, it means that's what happened.
-
@ZakTrading
I will share my experience with you.
I've seen and tested a lot of things, dukas copy tick data, even paid data and nothing worked perfectly.
What worked for me to have more quality in the tests and even prove the quality was "Develop an EA, with a wealth of control details".
What types of controls:
Timetable filters.
1st market tick filtering to identify when the market opened.
Spread filter and spread monitoring over time. (Some brokers, for example, Tickmil, had very varied spread years, which completely alters trading results between one period and another). The same happens with negotiations that depend on the market start time, some brokers change the start of market trading without prior notice.
Limitation of trades (Some brokers allow a maximum number of simultaneous trades).
Limitation on trading hours, always trade in a time window that you know the broker can have liquidity.
Removal of Stop Loss and Take Profit by (virtual) options, as many brokers unfortunately (create non-existent prices) and this generates stop losses that make no sense at all.
Lastly, the ideal is to do a small test, put your robot to operate day after day for at least 1 full week and in the following week perform a backtest on all models, tick, real tick and ohlc and compare the inputs to see if they are very close to what actually happened in the real market, if this is happening then you can find out which is the best backtest modeling and most appropriate for your trading style. -
@OntradingX Excellent advice.
-
@OntradingX very insightful reply.
