Profit / Loss

Post Reply
Simone
Posts: 9
Joined: 20 May 2013 08:27

Profit / Loss

Post by Simone »

Hi,

There is a function return me my "P/L" and "Cum P/L" ? thank you !
User avatar
WHS Support
Posts: 2443
Joined: 14 Feb 2013 10:27

Re: Profit / Loss

Post by WHS Support »

Hello Simone,

The P/L is a function of your current position. If your position is closed the P/L will return to 0.
The Cum. P/L is a function of all P/L of the day. This will be returned to 0 with the end of the business day.

(You might have some difference today in regards to the US futures due to the public holiday and halted session in the US)

Kind regards
Dominic
WHS
Simone
Posts: 9
Joined: 20 May 2013 08:27

Re: Profit / Loss

Post by Simone »

Thanks for the reply but I means if is possible obtain Profit/Loss and Cum P/L into Express Stop code to adapt target or stop price.

I can track the most recent P/L with istructions:
SetIntraPeriodUpdate();
PL = MarketPosition() * (close - EntryPrice());


But I don't be able to get the sum of the previous Profit-loss (Cum P/L).
Is it possible using CumPL as array instead series ?

Best regards
Simone
User avatar
WHS Support
Posts: 2443
Joined: 14 Feb 2013 10:27

Re: Profit / Loss

Post by WHS Support »

Hi Simone,

no, unfortunately this is not possible to program with an Express Stop. The problem is, as you already pointed out, that you cannot track back the Cum P/L.
You can only program this in a normal Express indicator which is generating signals (=> Sentimentor). There you have to put your Stop / Target levels as Input variables with the result that you can calculate the distance between the entry / stop&target and sum it up as long as you want. As all signals are always triggered at the close of the bar you do not need the function Entryprice().

Kind regards,
Timo
WH SelfInvest
Post Reply

Return to “WHS NANOTRADER - EXPRESS PROGRAMMING”