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
0 registered members (), 18,161 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
Different Bar Periods within same script? #432993
11/20/13 21:26
11/20/13 21:26
Joined: Apr 2013
Posts: 107
UK
G
Geek Offline OP
Member
Geek  Offline OP
Member
G

Joined: Apr 2013
Posts: 107
UK
Is it possible for Zorro to run 2 different Bar Periods within the same script?

For instance the script will be trading with Period = 240:

But I also want Zorro to check weekly Bar Period = 7200; conditions before entering a trade.

Thanks..

Re: Different Bar Periods within same script? [Re: Geek] #432997
11/20/13 21:49
11/20/13 21:49
Joined: Jul 2013
Posts: 522
D
dusktrader Offline
User
dusktrader  Offline
User
D

Joined: Jul 2013
Posts: 522
Yes it is possible, although I haven't done it myself yet. It explains more on the manual page here

I believe BarPeriod needs to be set to the smaller unit, and then TimeFrame to the larger unit. So in your example I think you would have BarPeriod=240 and then TimeFrame=30 (30x the BarPeriod).

Re: Different Bar Periods within same script? [Re: dusktrader] #432998
11/20/13 21:59
11/20/13 21:59
Joined: Apr 2013
Posts: 107
UK
G
Geek Offline OP
Member
Geek  Offline OP
Member
G

Joined: Apr 2013
Posts: 107
UK
Great stuff, thanks laugh

Re: Different Bar Periods within same script? [Re: Geek] #433008
11/21/13 08:24
11/21/13 08:24
Joined: Jul 2000
Posts: 28,022
Frankfurt
jcl Offline

Chief Engineer
jcl  Offline

Chief Engineer

Joined: Jul 2000
Posts: 28,022
Frankfurt
One remark - due to irregular holidays, a week has no fixed number of bars. Therefore you must synchronize the time frame with the start of the week. In the manual there's an example for synchronizing it to a day.


Moderated by  Petra 

Powered by UBB.threads™ PHP Forum Software 7.7.1