Gamestudio Links
Zorro Links
Newest Posts
Help with plotting multiple ZigZag
by degenerate_762. 04/30/24 23:23
M1 Oversampling
by 11honza11. 04/30/24 08:16
Trading Journey
by howardR. 04/28/24 09:55
Zorro Trader GPT
by TipmyPip. 04/27/24 13:50
Data from CSV not parsed correctly
by jcl. 04/26/24 11:18
AUM Magazine
Latest Screens
The Bible Game
A psychological thriller game
SHADOW (2014)
DEAD TASTE
Who's Online Now
1 registered members (AndrewAMD), 1,238 guests, and 3 spiders.
Key: Admin, Global Mod, Mod
Newest Members
firatv, wandaluciaia, Mega_Rod, EternallyCurious, howardR
19050 Registered Users
Previous Thread
Next Thread
Print Thread
Rate Thread
Portoflio Asset #474018
09/07/18 21:51
09/07/18 21:51
Joined: Feb 2018
Posts: 236
Italy
tradingest Offline OP
Member
tradingest  Offline OP
Member

Joined: Feb 2018
Posts: 236
Italy
Hi all,

I want to discuss this code below

Code:
while(asset(loop(Assets)))
{

var C = priceClose(0); 
var O = priceOpen(0);

print(TO_WINDOW,"n Asset = %s, C = %f, O = %f, day = %a", Asset,C,O,workday);

if(C > O)
enterLong();
}



We suppose that the portfolio have 3 different cross and before to open a new position for the current Asset I want verify if exists the open trade for the current asset in the loop. How Can I make?

Any suggestion?

Thanks

Re: Portoflio Asset [Re: tradingest] #474021
09/08/18 16:21
09/08/18 16:21
Joined: Feb 2017
Posts: 369
D
Dalla Offline
Senior Member
Dalla  Offline
Senior Member
D

Joined: Feb 2017
Posts: 369
You can check this with NumOpenLong and NumOpenShort.
Read about them and other useful trade stats here
http://zorro-project.com/manual/en/winloss.htm

Re: Portoflio Asset [Re: Dalla] #474025
09/08/18 19:42
09/08/18 19:42
Joined: Feb 2018
Posts: 236
Italy
tradingest Offline OP
Member
tradingest  Offline OP
Member

Joined: Feb 2018
Posts: 236
Italy
Originally Posted By: Dalla
You can check this with NumOpenLong and NumOpenShort.
Read about them and other useful trade stats here
http://zorro-project.com/manual/en/winloss.htm


Thanks Dalla

resolved!


Moderated by  Petra 

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