hi
I have been working hard on some massive changes.
In the process i have also added (see picture) a synoptic Excel export of filled orders (just for traders not wiring to SQL server, as the SQL server export was already in place).
Having changed the PNL computation engine, i have done a vast revision of all performance metrics, and i hope this can lead to a more powerful and precise selection process of strategies.
Let see how i have modified the PNL computations. (What follows may correct/change some points of previous post).
First of all i define:
<b><center>PNL = REALIZED GAIN + REALIZED LOSS + UNREALIZED</center></b>
further, i define:
INVESTMENT = REALIZED LOSS + UNREALIZED
We all know how to compute the PNL.
Now the crucial point is to compute in a meaningful way the REALIZED GAIN and LOSS.
Consider, for instance, the sequence of orders (ignore multipliers and commissions) and assume that the <b>current ASK is 5000</b>:
SELL 1 @ 2000
SELL 1 @ 7000
SELL 1 @ 12000
BUY 1 @ 10000
If we used the FIFO rule (as for taxes), we would be matching:
SELL 1 @ 2000
BUY 1 @ 10000
So a Realized of -8,000. The current PNL (including the trade to close) is 1,000.
So we have PNL = Realized + Unrealized => 1,000 = -8,000 + 9,000
Now, while this is probably favorable (in this example) for taxes (because we "realize" a negative amount), it's not good for an intuitive understanding of how the strategy is doing.
In fact, as traders, we would prefer that the profitable scalps be "matched" first (instead of using the FIFO rule), because that is how the strategy works: we invest and trade.
Infact, we would like to fist "recognize" the good trade:
SELL 1 @ 12000
BUY 1 @ 10000 a $ 2,000 profit trade
and then allocate the rest as "unrealized". So we prefer to think about it as:
PNL = REALIZED GAIN + REALIZED LOSS + UNREALIZED
1,000 = 2,000 + 0 - 1,000
This way, I think we can follow much better the strategy and the evolution of the REALIZED GAIN, as any strategy will naturally strive to maximize that part. We know we have made a good trade of 2,000 and an investment of 1,000 is ongoing.
So the basic idea boils down to: <b>we match first the good trades (realized GAIN), then we match the bad trades (realized LOSS) and what remains is "unrealized".</b> Clearly this affects the algorithm to compute the PNL components (and not the PNL itself).
The "total investment" can be seen as the unrealized + realized LOSS, where actually the unrealized is the actual part of the "investment" which can still create wealth ("ongoing investment").
(If you dont like or agree with this terminology/definitions or you have better wording, please let me know, it can be changed. This is just ongoing work and thinking... so anything can be done... )
Tom
<img src="http://www.elitetrader.com/vb/attachment.php?s=&postid=3250616" width="800" />
I have been working hard on some massive changes.
In the process i have also added (see picture) a synoptic Excel export of filled orders (just for traders not wiring to SQL server, as the SQL server export was already in place).
Having changed the PNL computation engine, i have done a vast revision of all performance metrics, and i hope this can lead to a more powerful and precise selection process of strategies.
Let see how i have modified the PNL computations. (What follows may correct/change some points of previous post).
First of all i define:
<b><center>PNL = REALIZED GAIN + REALIZED LOSS + UNREALIZED</center></b>
further, i define:
INVESTMENT = REALIZED LOSS + UNREALIZED
We all know how to compute the PNL.
Now the crucial point is to compute in a meaningful way the REALIZED GAIN and LOSS.
Consider, for instance, the sequence of orders (ignore multipliers and commissions) and assume that the <b>current ASK is 5000</b>:
SELL 1 @ 2000
SELL 1 @ 7000
SELL 1 @ 12000
BUY 1 @ 10000
If we used the FIFO rule (as for taxes), we would be matching:
SELL 1 @ 2000
BUY 1 @ 10000
So a Realized of -8,000. The current PNL (including the trade to close) is 1,000.
So we have PNL = Realized + Unrealized => 1,000 = -8,000 + 9,000
Now, while this is probably favorable (in this example) for taxes (because we "realize" a negative amount), it's not good for an intuitive understanding of how the strategy is doing.
In fact, as traders, we would prefer that the profitable scalps be "matched" first (instead of using the FIFO rule), because that is how the strategy works: we invest and trade.
Infact, we would like to fist "recognize" the good trade:
SELL 1 @ 12000
BUY 1 @ 10000 a $ 2,000 profit trade
and then allocate the rest as "unrealized". So we prefer to think about it as:
PNL = REALIZED GAIN + REALIZED LOSS + UNREALIZED
1,000 = 2,000 + 0 - 1,000
This way, I think we can follow much better the strategy and the evolution of the REALIZED GAIN, as any strategy will naturally strive to maximize that part. We know we have made a good trade of 2,000 and an investment of 1,000 is ongoing.
So the basic idea boils down to: <b>we match first the good trades (realized GAIN), then we match the bad trades (realized LOSS) and what remains is "unrealized".</b> Clearly this affects the algorithm to compute the PNL components (and not the PNL itself).
The "total investment" can be seen as the unrealized + realized LOSS, where actually the unrealized is the actual part of the "investment" which can still create wealth ("ongoing investment").
(If you dont like or agree with this terminology/definitions or you have better wording, please let me know, it can be changed. This is just ongoing work and thinking... so anything can be done... )
Tom
<img src="http://www.elitetrader.com/vb/attachment.php?s=&postid=3250616" width="800" />