Dukascopy Support Board
http://www.dukascopy.com/swiss/english/forex/jforex/forum/

Discussion? JForex Histrorical Tester results vs. the Live/Demo running
http://www.dukascopy.com/swiss/english/forex/jforex/forum/viewtopic.php?f=65&t=57444
Page 1 of 1

Author:  fprophet [ Sun 27 Sep, 2020, 21:34 ]
Post subject:  Discussion? JForex Histrorical Tester results vs. the Live/Demo running

Everyone knows that JForex back-testing a Strategy via the Historical Tester (Process all ticks) will not give the same results as what you get running live or demo (i.e. same code running 24hrs for a particular day on Live & Demo accounts will not match Historical Tester running over same 24hrs of Ticks).

We know fees & commissions might be different, but if we also know also that none of the Strategy's BUY / SELL decisions are made based on Equity, then that wouldn't account for the differences in timing of opening positions. I'm only ever buying or selling small fractions of Lots (EURUSD only, nothing exotic) so I never see any partial fills.

My onTick logic is very small (only checking if reached a Profit target) and the onBar logic is triggered every 5M bar, so I wouldn't expect any threading contention / congestion.

onBar logic uses various Indicators (various Periods) so I'm assuming this where the differences will most likely come from ...

I'm interested in other people's thoughts and experiences with this, and if anyone has discovered methods to minimize the differences?

Author:  fprophet [ Tue 29 Sep, 2020, 23:12 ]
Post subject:  Re: Discussion? JForex Histrorical Tester results vs. the Live/Demo running

account.getUseOfLeverage(); seems to return much higher values onTick in LIVE or DEMO running than in the Historical Tester - using the same code, same 24hrs of Ticks, same starting Balance/Equity, same account settings, etc.

But if the submitOrder timing is different due to Indicator value differences then that might explain the UOL% differences, maybe.
I guess I'm going to have to write Log of all data used to make every decision, then compare all the 3 different environments' data.

There is obviously something going on I don't understand .... :roll:

  Page 1 of 1