# What is PnL and How to Calculate It?

Profit and loss (PnL) is a commonly used term in trading, which refers to the profit or loss generated from a trader's positions. PnL can be either realized or unrealized. When a trader has open positions, the PnL is considered unrealized as it is still subject to change in response to market movements. However, when a trader closes their positions, the unrealized PnL becomes realized PnL.

## Realized PnL & Unrealized PnL Explained

The calculation of realized PnL is based on the entry and closing prices of the positions, and it has no direct relation to the mark price. On the other hand, the unrealized PnL constantly changes and is the primary factor for liquidations. The mark price is used to ensure that the calculation of unrealized PnL is accurate. It is important to note that PnL is always denoted in the settlement currency.&#x20;

### PnL Calculation <a href="#pnl-calculations" id="pnl-calculations"></a>

In order to determine your total PnL, traders must take both realized and unrealized PnL into account.&#x20;

> PnL = (mark price - entry price) \* orderPaperSize
>
> ROE= PnL/ position margin


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://about.jojo.exchange/jojo-1/v1-product-guides/faqs/what-is-pnl-and-how-to-calculate-it.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
