Gamestudio Links
Zorro Links
Newest Posts
Using ":L" & ":S" causes 2 possible bug(s) or is it bad coding?
by AndrewAMD
8 minutes 26 seconds ago
Help with Data import to T1
by OptimusPrime
Today at 19:44
How to ensamble multiple algos with advise calls?
by laz
Today at 18:53
Correlation -1.#IND00
by AndrewAMD
01/21/19 17:37
Basic thread safety question
by Superku
01/20/19 18:15
Blog Post: Get Historical Data from Darwinex REST API w/ Zorro
by AndrewAMD
01/19/19 22:19
Reseting a static variable - the next day
by OptimusPrime
01/19/19 19:48
AUM Magazine
Latest Screens
Worst Case Z
AckCon'18 - Lotter vs the World 2 - Preview Release
Evonet Beta v1.0 : Online Project Development Template
Lake scene
Who's Online
12 registered (OptimusPrime, AndrewAMD, jacek, Dalla, kvm, Quad, Iglarion, ibne, misiek, 3 invisible), 489 Guests and 7 Spiders online.
Key: Admin, Global Mod, Mod
Newest Members
jthbln, laz, ramonne, SibJac, Evael
18157 Registered Users
Topic Options
Rate This Topic
#470403 - 01/11/18 23:43 Many Partial Executions generate costs
Jesse_L Offline

Registered: 01/11/18
Posts: 3
Loc: Germany NRW
Z12 and Z2 trading with IB generate a lot of partial Executions. Sometimes the system buy and sold same position in 1 second. So it generate sometimes up to 8 real trades per minute! That means 30$ fees in a minute. The same effective position change would be possible with only one trade. Sometimes position size in forex is only 1K.
This is one reason I lost 40% of capital in last 10 weeks with Z12 and Z2.

Is it possible to set parameters for minimum trade size (for example 20K in forex)?
Is it possible to limit real trades of same currency per hour?
How can I prevent trades in opposite direction (buy/sell) at same time/ same day?
(Unfortunately all trades are real, no phantom trades)

Edited by Jesse_L (01/11/18 23:54)

#470404 - 01/12/18 10:56 Re: Many Partial Executions generate costs [Re: Jesse_L]
jcl Offline

Chief Engineer

Registered: 07/22/00
Posts: 26694
Loc: Frankfurt
For preventing that different algos go short and long at the same time, you must use virtual hedging. Otherwise the algos don't know of each other. And IB is not suited for Z12 and Z2. You can see in the backtest that the high margin requirement of IB basically eliminishes all profits, even with no simultanous opposite positions. Z1/2/12 are designed for Forex/CFD brokers with high leverage.

#470416 - 01/12/18 18:57 Re: Many Partial Executions generate costs [Re: jcl]
Jesse_L Offline

Registered: 01/11/18
Posts: 3
Loc: Germany NRW
It´s no problem between Z12 and Z2, this 2 systems have similar strategies and normaly trade in same direction.
Only trading Z12 alone generated following trades today morning:
action size basic price time fees$
SLD 8K EUR EUR.USD 1.21181 USD 09:47:22 4.03
BOT 3K EUR EUR.USD 1.21177 USD 09:47:21 4.03
BOT 13K EUR EUR.USD 1.21179 USD 09:47:21 4.03
BOT 3K EUR EUR.USD 1.21173 USD 09:47:19 4.03
SLD 15K USD USD.CAD 1.25290 CAD 05:20:21 4.03
SLD 3K USD USD.CAD 1.25291 CAD 05:20:16 4.03
SLD 27K USD USD.CAD 1.25291 CAD 05:20:16 4.03
SLD 4K USD USD.CAD 1.25291 CAD 05:20:15 4.03
BOT 10K GBP GBP.USD 1.35368 USD JAN 11 21:20:39 4.06
BOT 2K GBP GBP.USD 1.35368 USD JAN 11 21:20:38 4.06
SLD 2K GBP GBP.USD 1.35362 USD JAN 11 21:20:37 4.06
BOT 11K GBP GBP.USD 1.35368 USD JAN 11 21:20:30 4.06
BOT 12K GBP GBP.USD 1.35367 USD JAN 11 21:20:29 4.06
BOT 1K GBP GBP.USD 1.35368 USD JAN 11 21:20:21 4.06

It is visible that the algo open and close same position in some seconds and so only generate fees. The decision of position size seems to change in very short time, so the algo open one position after another. But it should open only one big position.
In my opinion the high IB margin leads not to problems. Capital in Zorro adjusted to IB cash works proper since some month. It caused no margin calls and should have no influence to algo performance (at least it should not be a reason for losses).

#470419 - 01/12/18 21:43 Re: Many Partial Executions generate costs [Re: Jesse_L]
mhdus Offline
Junior Member

Registered: 07/19/16
Posts: 87
Loc: Düsseldorf, Germany
Hi from NRW to NRW,
I'd like to add a bit to jcl's comments: please be aware that Z12 is a set of multiple algos, all running independently. So virtual hedging is the only option to limit opposite positions by different algos.
And as I have some experience with Z12 trading an IG (not IB) account (recently extremely profitable, by the way) I can safely state that executions as you are listing them here are not the normal Z12 behaviour. I guess it somehow relates to the fact that your orders are handled as "Odd Lot FX Transactions" (see The pattern looks as if the above are actually 3 Z12 trades only (and my Z12 on IG did very similar trades today: GBPUSD long, EURUSD long, USDCAD short) - somehow wildly split into pieces bei either IB, the API, or the Zorro IB Plugin. I'd further investigate into this direction (if you really want to trade Z12 with IB which is not recommended!).

#470420 - 01/12/18 22:00 Re: Many Partial Executions generate costs [Re: mhdus]
Zheka Offline
Senior Member

Registered: 07/03/17
Posts: 352
Odd Lots cannot be the reason. Despite the warning, nearly any irregular amount below stated IB minimum will still be executed normally, most often without any worsening of price.

#470474 - 01/16/18 19:56 Re: Many Partial Executions generate costs [Re: Zheka]
Jesse_L Offline

Registered: 01/11/18
Posts: 3
Loc: Germany NRW
Now I compared the trades by IB above with trade-logs in Zorro:
For example the 4 trades in EUR/USD (see above):
Name Type Asset Lots Open Close
CY Short EUR/USD 8 2018-01-12 08:47:00 2018-01-12 18:36:00
HP Short EUR/USD 3 2017-12-29 08:23:00 2018-01-12 08:47:00
HP Short EUR/USD 13 2018-01-03 00:20:00 2018-01-12 08:47:00
VO Short EUR/USD 3 2017-12-20 08:20:00 2018-01-12 08:47:00

All 4 positions are Short. Regarding time stamp 08:47 one was opened (8 Lots) and 3 were closed (3, 13, 3 Lots).
Also 8K are BOT and (3K+13K+3K) are SLD.
It seemes as if the 4 parted executions are initiated by Zorro, not by IB or API.
The trades follow different strategies (or what does CY, HP, VO mean?)
Every trade open and close in a single transaction at same time, resulting in repeated fees.
The question is, why Zorro not summarize all to one trade.
Do you have similar behaviour?


Gamestudio download | chip programmers | Zorro platform | shop | Data Protection Policy

oP group Germany GmbH | Birkenstr. 25-27 | 63549 Ronneburg / Germany | info (at)