Gamestudio Links
Zorro Links
Newest Posts
Zorro FIX plugin - Experimental
by flink. 04/21/24 07:12
Data from CSV not parsed correctly
by EternallyCurious. 04/20/24 21:39
M1 Oversampling
by 11honza11. 04/20/24 20:57
Scripts not found
by juergen_wue. 04/20/24 18:51
zorro 64bit command line support
by 7th_zorro. 04/20/24 10:06
StartWeek not working as it should
by jcl. 04/20/24 08:38
folder management functions
by VoroneTZ. 04/17/24 06:52
AUM Magazine
Latest Screens
The Bible Game
A psychological thriller game
SHADOW (2014)
DEAD TASTE
Who's Online Now
3 registered members (frutza, Quad, AndrewAMD), 385 guests, and 1 spider.
Key: Admin, Global Mod, Mod
Newest Members
EternallyCurious, howardR, 11honza11, ccorrea, sakolin
19047 Registered Users
Previous Thread
Next Thread
Print Thread
Rate Thread
Page 2 of 7 1 2 3 4 5 6 7
Re: New Zorro version 2.40.1 [Re: jcl] #483800
07/28/21 10:45
07/28/21 10:45
Joined: Jul 2000
Posts: 27,982
Frankfurt
jcl Offline OP

Chief Engineer
jcl  Offline OP

Chief Engineer

Joined: Jul 2000
Posts: 27,982
Frankfurt
If you get different trades from different versions, first check the log. Determine which trades are different and how. You will then normally quickly see the reason. If something is unclear, post the details here.

Re: New Zorro version 2.40.1 [Re: jcl] #483805
07/28/21 16:17
07/28/21 16:17
Joined: Dec 2019
Posts: 53
ozgur Offline
Junior Member
ozgur  Offline
Junior Member

Joined: Dec 2019
Posts: 53
I think Dataset functions are behaving differently compared to version 2.35. Is this expected?

Code:
Code
void run()
{
	
	if (is(INITRUN))
	{
		
		int handleID = 1;
		
		int len = dataParse(handleID, "ssss,i,f,f,f,f,f,f,f,f,f,f,f,f,f,f,f,f,i,i,i,i,i,i,i,i,i,i,i,i,i,i,i,i,i", "History\\Test.csv"); // Asset name 15 (4 * s - 1) character max 
		
		int i, j;
		
		for(i = 0; i < len; i++) {
			
			printf("Row %i: %s %i %i \n", i, dataStr(handleID, i, 1), dataInt(handleID, i, 5), dataInt(handleID, i, 38));
			
			for(j = 0; j < 8; j++) {
				
				printf("%f %f %i %i \n", dataVar(handleID, i, 6 + j), dataVar(handleID, i, 14 + j), dataInt(handleID, i, 22 + j), dataInt(handleID, i, 30 + j));
				
			}
			
		}
		
		// free data memory
		dataNew(handleID, 0, 0);
		
		printf("\n\n");
		
	}
}


Data: (Test.csv)
Code
Name,Apple,Orange1,Orange2,Orange3,Orange4,Orange5,Orange6,Orange7,Orange8,Melon1,Melon2,Melon3,Melon4,Melon5,Melon6,Melon7,Melon8,Grape1,Grape2,Grape3,Grape4,Grape5,Grape6,Grape7,Grape8,Plum1,Plum2,Plum3,Plum4,Plum5,Plum6,Plum7,Plum8,Berry
#AUD/CAD,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,
#AUD/CHF,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,
#AUD/JPY,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,
#AUD/NZD,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,
#AUD/USD,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,
#CAD/CHF,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,
#CAD/JPY,4,10,20,40,80,,,,,0.125,0.125,0.125,0.125,,,,,,,,,,,,,500,250,100,50,,,,,1
#CHF/JPY,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,
#EUR/AUD,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,
#EUR/CAD,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,
#EUR/CHF,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,
#EUR/GBP,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,
#EUR/JPY,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,
#EUR/NZD,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,
EUR/USD,4,12.5,25,50,100,,,,,0.125,0.125,0.125,0.125,,,,,4,4,4,4,,,,,500,250,100,50,,,,,1
#GBP/AUD,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,
#GBP/CAD,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,
#GBP/CHF,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,
GBP/JPY,4,10,20,40,80,,,,,0.125,0.125,0.125,0.125,,,,,8,8,8,8,,,,,500,250,100,50,,,,,1
#GBP/NZD,4,25,50,100,200,,,,,0.125,0.125,0.125,0.125,,,,,,,,,,,,,500,250,100,50,,,,,1
#GBP/USD,4,16,32,64,128,,,,,0.125,0.125,0.125,0.125,,,,,,,,,,,,,500,250,100,50,,,,,1
#NZD/CAD,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,
#NZD/CHF,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,
#NZD/JPY,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,
#NZD/USD,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,
#USD/CAD,5,10,30,50,80,130,,,,0.125,0.125,0.125,0.125,0.125,,,,,,,,,,,,500,250,100,50,25,,,,1
#USD/CHF,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,
#USD/JPY,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,


Result: (just part of it to give you an idea)

[Linked Image]

Re: New Zorro version 2.40.1 [Re: jcl] #483806
07/28/21 17:41
07/28/21 17:41
Joined: Feb 2021
Posts: 19
C
CpOo Offline
Newbie
CpOo  Offline
Newbie
C

Joined: Feb 2021
Posts: 19
Originally Posted by jcl
If you get different trades from different versions, first check the log. Determine which trades are different and how. You will then normally quickly see the reason. If something is unclear, post the details here.


No, I get exactly the same trades, same profit, annual growth rate, percent winning, MAE and so on... same report but the only difference between versions are those values and the (null) value in Simulation mode.

Re: New Zorro version 2.40.1 [Re: jcl] #483807
07/28/21 18:11
07/28/21 18:11
Joined: Jul 2000
Posts: 27,982
Frankfurt
jcl Offline OP

Chief Engineer
jcl  Offline OP

Chief Engineer

Joined: Jul 2000
Posts: 27,982
Frankfurt
Hmm, that sounds indeed strange. Can you contact support@opgroup.de and send them that script? They'll look into it.

Ozgur: I believe the first field is 0, not 1. Indices start with 0. The other column numbers are probably also wrong. Can you check if it works when you fix the numbers? Datasets expect a date in field 0, so I don't know what happens when it is missing, but possibly the old version got then some phantom field and thus worked with the wrong numbers.

Re: New Zorro version 2.40.1 [Re: jcl] #483809
07/28/21 18:42
07/28/21 18:42
Joined: Feb 2021
Posts: 19
C
CpOo Offline
Newbie
CpOo  Offline
Newbie
C

Joined: Feb 2021
Posts: 19
Originally Posted by jcl
Hmm, that sounds indeed strange. Can you contact support@opgroup.de and send them that script? They'll look into it.



I am using your Alice3b.c script for testing, but I am seeing the problem with any script. I tested in 2 different computers before writing here. It only happens on Test mode. Trade mode reports are Ok.

Last edited by CpOo; 07/28/21 22:14.
Re: New Zorro version 2.40.1 [Re: jcl] #483811
07/29/21 08:33
07/29/21 08:33
Joined: Jul 2000
Posts: 27,982
Frankfurt
jcl Offline OP

Chief Engineer
jcl  Offline OP

Chief Engineer

Joined: Jul 2000
Posts: 27,982
Frankfurt
Ah, ok. We'll check that and when it happens here too, it will be fixed. Since you found a bug in a release candidate, you're entitled for a 3 months free Zorro S subscription or support period - please contact Support for claiming the reward.

Ozgur: You can also claim a free subscription. The problem was indeed the missing date field, but both versions did not react consistently when it's missing. This will be fixed so that datasets with no date are now officially supported. But you must then still change your field numbers. The first field is 0 and the next integer field is 3, since the first 3 fields are needed for the string.

Re: New Zorro version 2.40.1 [Re: jcl] #483813
07/29/21 12:09
07/29/21 12:09
Joined: Jul 2000
Posts: 27,982
Frankfurt
jcl Offline OP

Chief Engineer
jcl  Offline OP

Chief Engineer

Joined: Jul 2000
Posts: 27,982
Frankfurt
2.40.2 is now out. Changes: Sharpe ratio fixed and datasets with no date field supported.

Re: New Zorro version 2.40.2 [Re: jcl] #483836
08/01/21 16:27
08/01/21 16:27
Joined: May 2018
Posts: 134
S
SBGuy Offline
Member
SBGuy  Offline
Member
S

Joined: May 2018
Posts: 134
My 2-minute bar options strategy surfaced a problem on 2.40.2

This is the code I use to load the options chain for the upcoming bar inside tock, when in Test mode.

The month() call is used to specify the T8 file name.

As you can see from the attached screenshot, month() stays at 1 when the actual month changed to February. This continues for the entire simulation period, LOOKBACK or not, resulting in no trades.

This code works fine in 2.35.6 and previous version going back at least couple of years.

Looks like month() is acting weird inside of tock(), or maybe elsewhere too.

Code

if (!Live)	{
		
		printf("\n[%d] TOCK -- [%s] Loading chain... ",utcHHMM, Asset);
		if(month()!=month(1) or Init) {		
			sprintf(OptionFile,"%s\\%s_%d%02d_m1.t8", HistFolder, Asset, year(),month());
			dataLoad(1,OptionFile,9);	
		}
		
		if (!Init)	{
			int Chain = contractUpdate(Asset,1,PUT|CALL); 
			if(Live || DEBUG) printf("\n[%d] TOCK -- [%s] %d contracts loaded...\n\n",utcHHMM, OptionFile, Chain);	
		}
	}

Attached Files
tock-chain-load.PNG (71 downloads)
Re: New Zorro version 2.40.2 [Re: jcl] #483837
08/01/21 17:09
08/01/21 17:09
Joined: May 2018
Posts: 134
S
SBGuy Offline
Member
SBGuy  Offline
Member
S

Joined: May 2018
Posts: 134
Another anomaly.

Assets with not enough historical data used to throw a "Warning 055: GRUB first yyy bars missing" message during Init only.

Now, v 2.40.2, throws up "Error 047: GRUB not enough ticks." during Init and every..... single.... bar. Even with a Verbose=1.

As a result, the large amount of error messages printed to the console window makes the simulation time unnecessarily long.

I could ignore(47), but that's probably not a good idea.

I suggest we go back to the Warning 055message during Init, like before.

Thanks!

Last edited by SBGuy; 08/01/21 17:11.
Re: New Zorro version 2.40.2 [Re: jcl] #483838
08/01/21 20:03
08/01/21 20:03
Joined: Sep 2019
Posts: 63
Naperville
K
kzhao Offline
Junior Member
kzhao  Offline
Junior Member
K

Joined: Sep 2019
Posts: 63
Naperville
I tested a couple of my strategies on 2.40.2. The SR in the result is always 0, while in 2.35 the SR has positive values.

Page 2 of 7 1 2 3 4 5 6 7

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