Skip to content

Profit and loss

Reconcile trading P&L from cash and holdings, separate price gain, income and costs, and distinguish a marked gain from a closed trade and a percentage return.

Profit and loss (P&L, or PnL) is the money gained or lost on a position, portfolio or trading activity over a specified period. Positive P&L is a profit; negative P&L is a loss. For a quant, it is the result that an execution and valuation ledger must explain: a correct forecast does not guarantee a profit after the actual fills, income and costs.

P&L needs a currency, a time window and an accounting scope. “Up 390” is incomplete without saying whether this means USD 390 today, since entry, before costs or after them. Here, P&L means the investment result of a trading account, rather than a company's full income statement.

A complete trade: USD 390, not USD 300

Consider an original synthetic trade in USD. Buy 100 shares at an actual fill price of 50 per share, pay a 5 entry commission, receive a 1-per-share cash dividend, then sell all shares at an actual fill price of 53, paying a 5 exit commission. The dividend stays in cash. There is no funding charge, cash interest, tax, currency conversion or external contribution or withdrawal during the measurement period.

The trade cash flows are:

EventCalculationCash change, USD
Buy and pay entry commission−100(50)−5-100(50)-5−5,005
Receive dividend100(1)100(1)+100
Sell and pay exit commission100(53)−5100(53)-5+5,295
Sum over the closed trade−5,005+100+5,295-5{,}005+100+5{,}295+390
The price gain alone is 100(53−50)=300100(53-50)=300. Including the dividend gives 400 before commissions, and the two commissions reduce this to 390 net P&L:
Net P&L=100(53−50)⏟300 price gain+100(1)⏟100 income−(5+5)⏟10 fees=390 USD.\text{Net P\&L} =\underbrace{100(53-50)}_{300\text{ price gain}} +\underbrace{100(1)}_{100\text{ income}} -\underbrace{(5+5)}_{10\text{ fees}} =390\text{ USD}.
Two routes to USD 390: trade cash flows of minus 5,005, plus 100 and plus 5,295; or price gain 300 plus dividend 100 minus commissions 10.
Two routes to USD 390: trade cash flows of minus 5,005, plus 100 and plus 5,295; or price gain 300 plus dividend 100 minus commissions 10.
Original synthetic USD example. Actual entry and exit fill prices are 50 and 53 per share for 100 shares. Both commissions are separate cash charges; no funding, tax or external capital flows are included.
These are fill prices. Any bid–ask spread or slippage already reflected in them has already affected cash paid and received. Subtracting an estimated spread again would charge the same friction twice. The explicit commissions are additional transaction costs.

Reconcile the cash journal to wealth

Cash flow alone is insufficient while a position remains open: buying shares turns cash into an asset rather than immediately losing the entire purchase price. Let account wealth be

Wt=Ct+qtmt,W_t=C_t+q_tm_t,

where CtC_t is cash, qtq_t is the shares held and mtm_t is the chosen mark in USD per share. With no external capital flows, total account P&L over the interval is WT−W0W_T-W_0.

Start the example account with USD 5,005 cash and no shares, immediately before entry. These snapshots reconcile the same trade:
SnapshotCash, USDSharesMark, USD/shareWealth, USDP&L since before entry, USD
Before entry5,0050—5,0050
Immediately after entry0100505,000−5
After dividend, just before exit100100535,400+395
After exit5,3950—5,395+390
The pre-exit row stipulates a mark of 53 after the dividend has been received; it does not assert a particular ex-dividend price path. At that point the price gain is unrealised because the shares are still held. The account's marked total P&L is 395, including the cash dividend and entry fee but excluding the not-yet-incurred exit commission. Selling at that same mark converts the stock into cash; the exit commission reduces wealth by 5. The final 5,395 minus 5,005 equals 390 check agrees with the closed cash journal.

A mark-to-market gain is therefore economically relevant without being a completed sale. It can reverse before exit, and a mark is not a promise that the full holding can be liquidated at that price. A report of estimated liquidation P&L would need to include its assumed exit prices and costs.

For partial sales or changing positions, a realised trade journal also needs a declared rule for matching sold quantities to their acquisition lots. The split between realised and unrealised gains can depend on that rule; total wealth still has to reconcile. The example sells the entire single purchase, so it avoids that ambiguity. These are economic ledger labels, not a statement of any jurisdiction's tax treatment.

For the event-by-event version, Positions, Trades, Fills and P&L derives how fills update both cash and holdings and shows how to reconcile partial execution. The link offers a public preview; the full lesson requires membership.

Dollar P&L does not specify a return

A percentage return requires a capital base. On the USD 5,005 initially committed to this fully funded account, including entry commission, the holding-period net return is
R=3905,005≈7.79%.R=\frac{390}{5{,}005}\approx7.79\%.

This is not an annualised figure: no holding-period length has been stipulated. Dividing by stock purchase notional, margin posted or a larger portfolio's equity answers different questions. In particular, an option premium, contract notional and margin requirement are different quantities; a P&L number alone cannot tell you which denominator is appropriate.

For an account with external capital flows, reconcile wealth after removing net contributions: a deposit increases account value but is not trading profit. Return measurement then also needs a timing convention. Likewise, reinvested dividends belong in the ledger once; do not add them again if the return data already include them.

A useful P&L report makes its scope visible: reporting currency and period, realised and marked components, income, costs and external capital flows. When converting from a P&L series to a risk-management loss series, check the sign: under the simple undiscounted convention, loss is minus P&L. Positive trading profit becomes a negative loss observation.

Sources

  • McNeil, Frey and Embrechts, Quantitative Risk Management: Concepts, Techniques and Tools, revised edition, Princeton University Press, 2015, §2.2.1, pp. 47–48. Defines portfolio value change and its opposite-signed loss; its initial fixed-portfolio model excludes intermediate income, which the journal here explicitly includes.
  • FINRA, Calculating Your Investment Returns, 4 December 2024. Explains why stock performance includes dividend income and investment fees as well as price appreciation. The trade and capital-base convention above are original examples.
Last updated
  • pnl
  • trading ledger
  • performance
  • mark to market
  • realised profit
← Back to the glossaryBack to top ↑