Gamestudio Links
Zorro Links
Newest Posts
Historical Data with the 64bit FXCM Plugin
by Martin_HH. 01/21/26 21:59
Buy A8 Pro Version
by Spirit. 01/21/26 21:37
ZorroGPT
by TipmyPip. 01/20/26 07:17
Bar missing bug?
by jcl. 01/19/26 10:47
400 free seamless texture pack downl. here !
by NeoDumont. 01/18/26 19:09
FXCM demo test failed
by qin. 01/13/26 13:53
AUM Magazine
Latest Screens
Rocker`s Revenge
Stug 3 Stormartillery
Iljuschin 2
Galactic Strike X
Who's Online Now
1 registered members (qin), 10,873 guests, and 8 spiders.
Key: Admin, Global Mod, Mod
Newest Members
Castromangos, Quantum, stephensdeborah, promfast, joe_kane
19193 Registered Users
Previous Thread
Next Thread
Print Thread
Rate Thread
Using leverage in backtests #484961
01/05/22 03:07
01/05/22 03:07
Joined: Jan 2022
Posts: 29
C
coinpump Offline OP
Newbie
coinpump  Offline OP
Newbie
C

Joined: Jan 2022
Posts: 29
Hi again, new zorro s user here.

How can I use leverage in my tests? I changed the "market" column in the assets but I don't think I'm doing it correctly. Is there a way to do it programmatically in the script?

Thank you! Great software by the way.

Re: Using leverage in backtests [Re: coinpump] #484974
01/05/22 11:32
01/05/22 11:32
Joined: Apr 2008
Posts: 599
Austria
Petra Offline
Support
Petra  Offline
Support

Joined: Apr 2008
Posts: 599
Austria
Set MarginCost to the current price divided by leverage.

Re: Using leverage in backtests [Re: Petra] #484979
01/05/22 15:22
01/05/22 15:22
Joined: Jan 2022
Posts: 29
C
coinpump Offline OP
Newbie
coinpump  Offline OP
Newbie
C

Joined: Jan 2022
Posts: 29
Can you give me an example doing this inside a script? Is it as simple as this?

MarginCost = price(0) / 3;

I have tried changing the MarginCost in the assets file, but the test results are the same. Can you give me an example of changing the leverage with both the assets file and inside a script?

Last edited by coinpump; 01/05/22 15:46.

Moderated by  Petra 

Powered by UBB.threads™ PHP Forum Software 7.7.1