Gamestudio Links
Zorro Links
Newest Posts
Zorro 2.70
by jcl. 09/29/25 09:24
optimize global parameters SOLVED
by dBc. 09/27/25 17:07
ZorroGPT
by TipmyPip. 09/27/25 10:05
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
6 registered members (TipmyPip, Niels, dBc, Ed_Love, 3run, 1 invisible), 17,577 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
Pause Trading - how to #475949
01/15/19 09:34
01/15/19 09:34
Joined: Apr 2018
Posts: 46
M
MINER Offline OP
Newbie
MINER  Offline OP
Newbie
M

Joined: Apr 2018
Posts: 46
Hello Community..

I would like to add a condition to my script which will be commanding Zorro to wait for lets say 2 bars after exiting a trade and then check if conditions are true again and enter another trade....which function is best suited for this?

Thank in advance, MINER.

Re: Pause Trading - how to [Re: MINER] #475950
01/15/19 10:10
01/15/19 10:10
Joined: Apr 2018
Posts: 46
M
MINER Offline OP
Newbie
MINER  Offline OP
Newbie
M

Joined: Apr 2018
Posts: 46
I have included trade LifeTime = 4,
I would like zorro to pause after 4th bar and check conditions again in the 6th bar for example. so i would like zorro to pause trading for two bars.

Re: Pause Trading - how to [Re: MINER] #475951
01/15/19 12:05
01/15/19 12:05
Joined: Apr 2018
Posts: 46
M
MINER Offline OP
Newbie
MINER  Offline OP
Newbie
M

Joined: Apr 2018
Posts: 46
Im wondering if its possible to set a delay timer between trades? I'm working on automating a strategy, but there are some times when conditions are met that trades will open and close faster then you can blink. I'm wondering if we can say "For the next 10 bars, do not open any new trades", or "For the next 60 minutes do not open any new trades"

Re: Pause Trading - how to [Re: MINER] #475989
01/16/19 16:39
01/16/19 16:39
Joined: Aug 2018
Posts: 101
O
OptimusPrime Offline
Member
OptimusPrime  Offline
Member
O

Joined: Aug 2018
Posts: 101
Here are some examples from the Manual you can adapt

//Delay every 30 seconds
for(OrderDelay = 0; OrderDelay< 10*30; OrderDelay += 30)
{
//////
}


/////////

// Use an entry limit and an entry delay for not entering trades at the same time
// Call this function before entering a trade
/////////
void setDelay(var Seconds)
{
static int PrevBar = 0;
static var Delay = 0;

if(Bar != PrevBar) { // reset delay at any new bar
Delay = 0;
PrevBar = Bar;
}
Delay += Seconds; // increase delay within the bar
OrderDelay = Delay;
Entry = -0.2*PIP * sqrt(Delay); // entry limit for additional profit


Thanks so much,

OptimusPrime

Re: Pause Trading - how to [Re: OptimusPrime] #476006
01/17/19 11:04
01/17/19 11:04
Joined: Apr 2018
Posts: 46
M
MINER Offline OP
Newbie
MINER  Offline OP
Newbie
M

Joined: Apr 2018
Posts: 46
this is very useful to me Optimus, thank you


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