Gamestudio Links
Zorro Links
Newest Posts
Blobsculptor tools and objects download here
by NeoDumont. 03/28/24 03:01
Issue with Multi-Core WFO Training
by aliswee. 03/24/24 20:20
Why Zorro supports up to 72 cores?
by Edgar_Herrera. 03/23/24 21:41
Zorro Trader GPT
by TipmyPip. 03/06/24 09:27
VSCode instead of SED
by 3run. 03/01/24 19:06
AUM Magazine
Latest Screens
The Bible Game
A psychological thriller game
SHADOW (2014)
DEAD TASTE
Who's Online Now
5 registered members (Quad, AndrewAMD, Imhotep, TipmyPip, Edgar_Herrera), 809 guests, and 4 spiders.
Key: Admin, Global Mod, Mod
Newest Members
sakolin, rajesh7827, juergen_wue, NITRO_FOREVER, jack0roses
19043 Registered Users
Previous Thread
Next Thread
Print Thread
Rate Thread
Strategy shows a loss when it is not #483719
07/16/21 18:26
07/16/21 18:26
Joined: Jul 2021
Posts: 8
T
TalonTrades Offline OP
Newbie
TalonTrades  Offline OP
Newbie
T

Joined: Jul 2021
Posts: 8
Why does my short, which closes below the entry price based on the TakeProfit parameter, show as a loss?

I was writing an actual strategy based on 1 minute bars and wins were showing up as losses, so I made this dummy strategy for troubleshooting purposes.

I confirmed it is definitely closing the trade based on the TakeProfit parameter but not sure why it is a loss when I enter with enterShort() .

Another sanity check was switching the entry to enterLong(), in which case it accurately shows a loss 40 ticks below my entry.

Attached Files enter-short.png
Last edited by TalonTrades; 07/16/21 18:43.
Re: Strategy shows a loss when it is not [Re: TalonTrades] #483720
07/16/21 19:31
07/16/21 19:31
Joined: Feb 2017
Posts: 1,718
Chicago
AndrewAMD Online
Serious User
AndrewAMD  Online
Serious User

Joined: Feb 2017
Posts: 1,718
Chicago
There can be many reasons for this.

Set Verbose to 7 | DIAG and read your log files in your Log folder. (You set LOGFILE, which is good.)

Also, verify that you configured your asset list correctly.

See also:
https://zorro-project.com/manual/en/trouble.htm

Re: Strategy shows a loss when it is not [Re: TalonTrades] #483721
07/16/21 20:22
07/16/21 20:22
Joined: Jul 2021
Posts: 8
T
TalonTrades Offline OP
Newbie
TalonTrades  Offline OP
Newbie
T

Joined: Jul 2021
Posts: 8
It was my assets config.

The one I was testing was @ES#, which is the E-Mini S&P Futures contract. I copied the settings from the IB example. The PipCost was set to .025 and should have been 12.5. Makes sense.

Thanks Andrew!

Last edited by TalonTrades; 07/16/21 20:25.

Moderated by  Petra 

Powered by UBB.threads™ PHP Forum Software 7.7.1