Login Page - Create Account

Support Board


Date/Time: Sat, 15 Mar 2025 16:12:39 +0000



[Programming Help] - The current P&L of the account as a percentage of the starting capital?

View Count: 468

[2022-07-11 07:46:33]
Luchs - Posts: 23
I use Spreadsheetstudy extensively and find it great.

However, there is one thing I haven't got right yet: At the beginning of the day, I always enter the starting capital from the morning in a field.

I would now like to display the current P&L as a percentage of the morning capital. Not closed, but running, i.e. with the currently open positions.

Does anyone have an idea how this could work?
[2022-07-11 13:47:55]
Sawtooth - Posts: 4183
You would need to use the Spreadsheet System for Trading study to get the Open P/L (in J10).

This example might be of some help:
Spreadsheet Example Formulas and Usage: Calculate Daily Net Closed Profit/Loss After Commissions
[2022-07-11 19:04:33]
Luchs - Posts: 23
Thank you for the advice.

But in fact I know how to calculate the closed P&L.

How about the OPEN P&L too? In realtime, so to speak. That's the issue.
[2022-07-11 19:23:01]
Sawtooth - Posts: 4183
How about the OPEN P&L too? In realtime, so to speak. That's the issue.
The Open P/L is in realtime.
So Closed P/L + Open P/L = Today's Realtime P/L

So:
(J45 + J10) / Starting Capital = Current P/L % of Morning Capital.
[2022-07-12 08:28:13]
Luchs - Posts: 23
I also thought that this is how it works. Unfortunately, however, nonsense comes out of it.

... and as I just see, J45 gives a wrong value. There is about 800 USD profit, although I have not made any trade today.

Now the troubleshooting begins ...
[2022-07-12 08:46:37]
Luchs - Posts: 23
I've found it: For some unknown reason, the entry and exit orders did not match. I have now entered today's date in the Chart Settings under Trading and - voilá - it works.

Your hints have brought me to the fact that I have actually thought correctly, but something was wrong not with Sierra Chart but the settings.

Thanks again.
[2022-07-19 06:24:41]
Luchs - Posts: 23
In case anyone ever needs to know in the future: In my opinion only the field J103 shows the correct value when it comes to the whole trade.

The fields J10 and J11 together do not show the correct value once a trade has been down scaled.

To post a message in this thread, you need to log in with your Sierra Chart account:

Login

Login Page - Create Account