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
Eigenwerbung
by jcl. 04/26/24 11:08
AUM Magazine
Latest Screens
The Bible Game
A psychological thriller game
SHADOW (2014)
DEAD TASTE
Who's Online Now
2 registered members (degenerate_762, AndrewAMD), 877 guests, and 5 spiders.
Key: Admin, Global Mod, Mod
Newest Members
wandaluciaia, Mega_Rod, EternallyCurious, howardR, 11honza11
19049 Registered Users
Previous Thread
Next Thread
Print Thread
Rate Thread
"wait" command is not working when calling "contractVal()" #481649
10/12/20 13:16
10/12/20 13:16
Joined: Sep 2020
Posts: 22
Z
zzy Offline OP
Newbie
zzy  Offline OP
Newbie
Z

Joined: Sep 2020
Posts: 22
Dear developers,

It seems that "wait" command is not working when calling "contractVal" in the script. I am not sure if this is a bug or not.

I got this results by using the following script (the elapsed time should be about 4 seconds, but here is only about 0):
==================
z_PayOff compiling.................... ok

Start
Time Elapsed: 0.002 seconds

Finish
==================


Here is the test script generated based on the "PayOff.c" script in Strategy folder:
==================
#include <contract.c>

void main()
{
printf("\nStart");
CONTRACT C;
contractVal(&C,C.fUnl,0.15,0.01,0.01);
var Time = timer();
wait(4000);
printf("\nTime Elapsed: %.3f seconds",(timer()-Time)/1000);
quit("\nFinish");
}
==================

Re: "wait" command is not working when calling "contractVal()" [Re: zzy] #481650
10/12/20 16:16
10/12/20 16:16
Joined: Jul 2000
Posts: 27,986
Frankfurt
jcl Offline

Chief Engineer
jcl  Offline

Chief Engineer

Joined: Jul 2000
Posts: 27,986
Frankfurt
I cannot confirm a bug with wait, but you're calling contractVal with an unitialized struct. You got probably a crash in the R library.

Re: "wait" command is not working when calling "contractVal()" [Re: jcl] #481651
10/13/20 08:13
10/13/20 08:13
Joined: Sep 2020
Posts: 22
Z
zzy Offline OP
Newbie
zzy  Offline OP
Newbie
Z

Joined: Sep 2020
Posts: 22
You are right. "RQuantLib not installed". I installed the package and now it is working properly! Thanks a lot.


Moderated by  Petra 

Powered by UBB.threads™ PHP Forum Software 7.7.1