Gamestudio Links
Zorro Links
Newest Posts
ZorroGPT
by TipmyPip. 03/08/26 18:50
zorro with ccxt?
by opm. 03/03/26 03:17
WFO Training with parallel cores Zorro64
by Martin_HH. 02/26/26 16:03
Zorro version 3.0 prerelease!
by TipmyPip. 02/25/26 16:38
AUM Magazine
Latest Screens
Dorifto samurai
Shadow 2
Rocker`s Revenge
Stug 3 Stormartillery
Who's Online Now
1 registered members (Quad), 15,223 guests, and 1 spider.
Key: Admin, Global Mod, Mod
Newest Members
the1, alx, ApprenticeInMuc, PatrickH90, USER0328
19200 Registered Users
Previous Thread
Next Thread
Print Thread
Rate Thread
Bollinger Bands #423445
05/29/13 22:23
05/29/13 22:23
Joined: Apr 2013
Posts: 107
UK
G
Geek Offline OP
Member
Geek  Offline OP
Member
G

Joined: Apr 2013
Posts: 107
UK
Quote:
vars Close = series(priceClose());
vars Price = series(price());

var *BBAnd1Upper = series(rRealUpperBand);
var *BBAnd1Lower = series(rRealLowerBand);


if (priceClose() <= (rRealLowerBand))
enterLong();

else if (priceClose() >= (rRealUpperBand))
enterShort();



I am just testing out the Bollinger Bands indicators, and the above part of the code seems to work.

But I am not sure if there something missing from this code? Such as the below, which I found from an older post on this forum..

Quote:
BBands(Close,19,1,1,MAType_SMA));


I have tried to put in this part above but it gives me a syntax error... Just want to make sure that I am going about this correctly??

Cheers.

Re: Bollinger Bands [Re: Geek] #423461
05/30/13 10:22
05/30/13 10:22
Joined: Jul 2000
Posts: 28,083
Frankfurt
jcl Offline

Chief Engineer
jcl  Offline

Chief Engineer

Joined: Jul 2000
Posts: 28,083
Frankfurt
Yes, you must call the BBands function before you can use rRealLowerBand or rRealUpperBand. See the indicators.c example.

Re: Bollinger Bands [Re: jcl] #423937
06/08/13 13:03
06/08/13 13:03
Joined: Apr 2013
Posts: 107
UK
G
Geek Offline OP
Member
Geek  Offline OP
Member
G

Joined: Apr 2013
Posts: 107
UK
Thank you, this is now working.


Moderated by  Petra 

Gamestudio download | 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