Gamestudio Links
Zorro Links
Newest Posts
Help with plotting multiple ZigZag
by degenerate_762. 04/30/24 23:23
M1 Oversampling
by 11honza11. 04/30/24 08:16
Trading Journey
by howardR. 04/28/24 09:55
Zorro Trader GPT
by TipmyPip. 04/27/24 13:50
Data from CSV not parsed correctly
by jcl. 04/26/24 11:18
Why Zorro supports up to 72 cores?
by jcl. 04/26/24 11:09
AUM Magazine
Latest Screens
The Bible Game
A psychological thriller game
SHADOW (2014)
DEAD TASTE
Who's Online Now
4 registered members (AndrewAMD, SBGuy, TipmyPip, ozgur), 923 guests, and 6 spiders.
Key: Admin, Global Mod, Mod
Newest Members
firatv, wandaluciaia, Mega_Rod, EternallyCurious, howardR
19050 Registered Users
Previous Thread
Next Thread
Print Thread
Rate Thread
Same script, different result #473586
07/24/18 20:52
07/24/18 20:52
Joined: Jan 2018
Posts: 18
M
Meini Offline OP
Newbie
Meini  Offline OP
Newbie
M

Joined: Jan 2018
Posts: 18
I developed a trading script and trained it with walk forward over a set period of time. I did quite a bit of testing and changing until I got that result. So I created a copy of the C file as I wanted to develop it further without losing what I already had.

You would expect that this identical copy of the code, being trained with the same time period and currency pair gives you the same result. But in fact the training result is significantly worse than when I train the original.

I am at a loss. Any ideas?

Re: Same script, different result [Re: Meini] #473593
07/25/18 16:39
07/25/18 16:39
Joined: Sep 2003
Posts: 929
Spirit Offline

Moderator
Spirit  Offline

Moderator

Joined: Sep 2003
Posts: 929
If the script is the same then something else is different, I would next compare the training data. Maybe you have selected a different account while training or testing.

Re: Same script, different result [Re: Spirit] #473596
07/25/18 20:00
07/25/18 20:00
Joined: Jan 2018
Posts: 18
M
Meini Offline OP
Newbie
Meini  Offline OP
Newbie
M

Joined: Jan 2018
Posts: 18
Thanks for your input Spirit. Yes, I fully agre , I did some more testing yesterday and I am getting a bit closer. I am sure I will find out what's going on. Experience tells me it usually is something quite simple that I overlooked, but this one is weird. Feels like a maybe variable may not be properly initialised. I'll report back with any relevant findings.

Re: Same script, different result [Re: Meini] #473597
07/25/18 21:58
07/25/18 21:58
Joined: Jan 2018
Posts: 18
M
Meini Offline OP
Newbie
Meini  Offline OP
Newbie
M

Joined: Jan 2018
Posts: 18
Here is a preliminary finding. It seems be related to DataSplit. What happens if only NumWFOCycles is set but DataSplit is not set in the script? I seem to get inconsistent training results if DataSplit is not set.

Re: Same script, different result [Re: Meini] #473604
07/26/18 07:22
07/26/18 07:22
Joined: Sep 2003
Posts: 929
Spirit Offline

Moderator
Spirit  Offline

Moderator

Joined: Sep 2003
Posts: 929
If datasplit is not set it has a default value. But maybe that goes in the right direction, maybe some other variable in the script is not initialized in initrun and then gets the value from the last run.

Re: Same script, different result [Re: Spirit] #473608
07/26/18 11:40
07/26/18 11:40
Joined: Jan 2018
Posts: 18
M
Meini Offline OP
Newbie
Meini  Offline OP
Newbie
M

Joined: Jan 2018
Posts: 18
Ok, I ran some more tests and it looks like I am getting closer. With the same DataSplit value I get different results depending on whether I first delete the old *.par files from a previous test or not. (This would also explain my observation in the initial post.) I have no idea if that is by design or if it is a bug. I will do some more testing to get a clearer picture and keep you posted....

Re: Same script, different result [Re: Meini] #473625
07/28/18 02:15
07/28/18 02:15
Joined: Jan 2018
Posts: 18
M
Meini Offline OP
Newbie
Meini  Offline OP
Newbie
M

Joined: Jan 2018
Posts: 18
Hours of testing, with about 100 individual tests later, and it seems the issue has at least two different causes:

1. Deleting all training related data files *.par before changing DataSplit and running a new training session sometimes has an influence on the outcome.

2. If DataSplit is not set, it seems to change its value from 0 to 85% at some point. The problem surfaced because, I used its value in calculations at a point in the program when it was still 0, it later changed to 85%. This explains at least some of the behaviour.

There is a clue about this inconsistency in the manual - which statement is the correct one?

Quote:
Walk Forward Optimization
If DataSplit is not set otherwise, WFO uses a default training period of 85% and a default test period of 15%.

Quote:
DataSplit
Splits the simulation in a training period (given in percent) and a following test period. F.i. when set at 60, the training period has a length of 60% and the test period has a length of 40%. This works with or without WFO and ensures that the test always uses out-of-sample data.
Typical range:
50..90 (default = 0 = no separate training / test period).


Conclusion: Something needs to be sorted out by the Zorro Developers and/or manual author. Or maybe I am just not understanding things right...

Re: Same script, different result [Re: Meini] #473630
07/29/18 06:20
07/29/18 06:20
Joined: Sep 2003
Posts: 929
Spirit Offline

Moderator
Spirit  Offline

Moderator

Joined: Sep 2003
Posts: 929
I believe, when datasplit is 0, it is automatically set to 85 in wfo, otherwise wfo would not work because there is no training period.


Moderated by  Petra 

Gamestudio download | chip programmers | Zorro platform | shop | Data Protection Policy

oP group Germany GmbH | Birkenstr. 25-27 | 63549 Ronneburg / Germany | info (at) opgroup.de

Powered by UBB.threads™ PHP Forum Software 7.7.1