Gamestudio Links
Zorro Links
Newest Posts
optimize global parameters SOLVED
by dBc. 09/27/25 17:07
ZorroGPT
by TipmyPip. 09/27/25 10:05
Release 2.68 replacement of the .par format
by Martin_HH. 09/23/25 20:48
assetHistory one candle shift
by jcl. 09/21/25 11:36
Plugins update
by Grant. 09/17/25 16:28
AUM Magazine
Latest Screens
Rocker`s Revenge
Stug 3 Stormartillery
Iljuschin 2
Galactic Strike X
Who's Online Now
2 registered members (TipmyPip, AndrewAMD), 16,415 guests, and 5 spiders.
Key: Admin, Global Mod, Mod
Newest Members
krishna, DrissB, James168, Ed_Love, xtns
19168 Registered Users
Previous Thread
Next Thread
Print Thread
Rate Thread
Beginner question : vars and series #460807
07/15/16 15:11
07/15/16 15:11
Joined: Jun 2016
Posts: 2
france
J
jc45 Offline OP
Guest
jc45  Offline OP
Guest
J

Joined: Jun 2016
Posts: 2
france
Hello everybody,
I'm a beginner and I'm in trouble with this simple code :

function run()
{
BarPeriod = 1440;
set(PRELOAD);
LookBack = 250;

asset("vxmt");
vars priceVXMT = series(priceClose());
asset("vxv");
vars priceVXV = series(priceClose());

vars ratio = series(priceVXV/priceVXMT);
vars ratioSMA = series(SMA(ratio,20));

}

error in line 16:
Syntax error : wrong type DIV:POINTER:POINTER:POINTER
<vars ratio = series(priceVXV/priceVXMT);>

Any idea ? Any help is welcome.
Thank's in advance !
JC

Re: Beginner question : vars and series [Re: jc45] #460809
07/15/16 16:18
07/15/16 16:18
Joined: Apr 2016
Posts: 5
W
wingt Offline
Newbie
wingt  Offline
Newbie
W

Joined: Apr 2016
Posts: 5
try this:
vars ratio = series(priceVXV[0]/priceVXMT[0]);

Re: Beginner question : vars and series [Re: wingt] #460811
07/15/16 16:48
07/15/16 16:48
Joined: Jun 2016
Posts: 2
france
J
jc45 Offline OP
Guest
jc45  Offline OP
Guest
J

Joined: Jun 2016
Posts: 2
france
Thank's a a lot Wingt !
I try quickly and it seems to work.
JC


Moderated by  Petra 

Powered by UBB.threads™ PHP Forum Software 7.7.1