Dukascopy
 
 
Wiki JStore Search Login

Attention! Read the forum rules carefully before posting a topic.

    Try to find an answer in Wiki before asking a question.
    Submit programming questions in this forum only.
    Off topics are strictly forbidden.

Any topics which do not satisfy these rules will be deleted.

Discussion? JForex Histrorical Tester results vs. the Live/Demo running
 Post subject: Discussion? JForex Histrorical Tester results vs. the Live/Demo running Post rating: 0   New post Posted: Sun 27 Sep, 2020, 21:34 
User avatar

User rating: 1
Joined: Fri 14 Sep, 2012, 02:25
Posts: 55
Location: New Zealand, Christchurch
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?


 
 Post subject: Re: Discussion? JForex Histrorical Tester results vs. the Live/Demo running Post rating: 0   New post Posted: Tue 29 Sep, 2020, 23:12 
User avatar

User rating: 1
Joined: Fri 14 Sep, 2012, 02:25
Posts: 55
Location: New Zealand, Christchurch
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:


 

Jump to:  

cron
  © 1998-2024 Dukascopy® Bank SA
On-line Currency forex trading with Swiss Forex Broker - ECN Forex Brokerage,
Managed Forex Accounts, introducing forex brokers, Currency Forex Data Feed and News
Currency Forex Trading Platform provided on-line by Dukascopy.com