Skip to content
All library documents

Calculating Unrealized P&L for Filled FIX Orders

Article Quant Q&A · Author: Reza Str

Summary

The document explains that FIX is a messaging protocol and does not define a standard field that directly reports the current floating profit or loss of a filled order. The suggested calculation uses execution-report details such as fill price and quantity, together with a reference market price, to estimate the position’s profit or loss against that market price. This is commonly described as unrealized P&L.

The basic calculation becomes more involved when an account has prior closed trades or multiple open fills at different prices. In those cases, the result depends on how positions and cost basis are tracked and aggregated. The discussion identifies the required information and the main complications but does not give a complete formula, accounting convention, or treatment of fees and financing. A FIX identifier can locate the order, but the protocol itself is not a substitute for maintaining position and valuation records.

Key ideas

  • FIX does not provide a standard tag for current unrealized P&L on a filled order.
  • A basic estimate combines fill price and quantity with a current reference price.
  • Multiple fills and previously closed trades make position-level P&L accounting more involved.
  • Order identifiers and execution reports provide inputs, while P&L calculation must be handled by the trading system.

Tags

Full text
# Calculating floating P&L of a FIX-order


# Calculating floating P&L of a FIX-order












How to fetch floating p/l(current) of a "filled" FIX-Order (either buy/sell)?(by its FIX-ID/order ID)

I asked my FIX provider(Integral) & they said, there's no specific tag for that/not a standard FIX practice, but it can be calculated on my side.(via different methods) Is there any way to calculate floating p/l of a fix-order?(against current market price)

## Answer by rupweb (score 1, accepted)

https://quant.stackexchange.com/a/25287

FIX is just the message protocol so the PnL for a filled order (an execution report) on your side by taking the price and volume of the execution report and a reference price when you get the execution report, then calculate your PnL...

## Answer by Wapiti (score 0)

https://quant.stackexchange.com/a/25296

So you are asking about what is usually called Unrealized P&L. There are multiple ways to do this. It can be as simple as rupweb points out, but there are some complications, for example when you have previous closed trades, or have multiple open trades at multiple prices. For some detailed information on this, including a formula you can just copy, check out TT's FIX Adapter documentation.

Shown in full with attribution under the source's licence. Licence: CC BY-SA 4.0 (Stack Exchange)

This summary was written by Stratmill's research agent from the original; it is not a copy of the source.