O que e PnL?
O que e PnL?
PnL stands for Lucros e Perdas. It is the measure of how much money voce tem made or lost on your trades. Understanding PnL is essential for evaluating seu trading performance and making informed decisions about sua estrategia.
Realized vs UnPnL realizado
There are two types of PnL, and the distinction entre om is critical.
Realized PnL
Realized PnL is o lucro or loss from trades that have been closed. Once you sell an asset you bought or close a futures position, o resultadoing gain or loss becomes “realized.” It is locked in and cannot change.
Exemplo:
- You buy ETH at $2,000 and sell at $2,100.
- Realized PnL = $2,100 - $2,000 = +$100 (before fees).
- This $100 is yours. It does not change independentemente de what ETH does next.
UnPnL realizado
UnPnL realizado is the paper profit or loss on positions that are still open. It changes constantly as o mercado price moves. UnPnL realizado is not real money until you close a posicao.
Exemplo:
- You buy ETH at $2,000. The preco atual is $2,150.
- UnPnL realizado = $2,150 - $2,000 = +$150.
- But if ETH drops to $1,950 before you sell, your PnL nao realizado becomes -$50.
- O lucro was never real until you closed the trade.
Why the Distinction Matters
Many traders make the mistake of treating unrealized gains as real money. They see their portfolio up 20% and feel wealthy, but a market correction can erase those gains overnight. Only PnL realizado impacts your actual account balance.
In grid trading, this distinction is especially important. A grid bot may show significant unrealized losses during a price dip (because it has bought at multiple levels above the preco atual), while simultaneously having healthy PnL realizado from completed TP cycles.
How to Calculate PnL
Basic PnL Calculation
For a long position: PnL = (Exit Price - Entry Price) x Quantity
For a short position: PnL = (Entry Price - Exit Price) x Quantity
Including Fees
Real PnL must account for all trading costs: Net PnL = Gross PnL - Trading Fees - Funding Costs
Exemplo:
- Buy 0.5 ETH at $2,000 (cost: $1,000).
- Sell 0.5 ETH at $2,100 (proceeds: $1,050).
- Gross PnL: +$50.
- Trading fees (0.02% maker, ambos sides): $1,000 x 0.02% + $1,050 x 0.02% = $0.41.
- Funding paid (held position for 24 hours at 0.01%): $1,000 x 0.01% x 3 = $0.30.
- Net PnL: $50 - $0.41 - $0.30 = $49.29.
Calculating ROI
ROI (Return on Investment) expresses your PnL as a percentage of your initial capital:
ROI = (Net PnL / Initial Capital) x 100
Exemplo:
- Initial capital: $5,000.
- Net PnL after one month: $250.
- ROI = ($250 / $5,000) x 100 = 5% per month.
Annualized ROI
To compare strategies over different time periods, annualize your ROI:
Annualized ROI = Monthly ROI x 12 (simple method)
Or for compound returns:
Annualized ROI = ((1 + Monthly ROI) ^ 12 - 1) x 100
Using the 5% monthly example: (1.05^12 - 1) x 100 = 79.6% annualized (compounded).
PnL in Grid Trading
Grid bots have a unique PnL profile:
Realized PnL accumulates with every completed buy-TP cycle. Each cycle adds a small, consistent profit. Over time, these add up.
UnPnL realizado fluctuates based on open positions. When o preco is near o bottom of o grid, PnL nao realizado may be negative because positions bought at higher levels are underwater. When o preco is near the top, PnL nao realizado is positive.
Total PnL = Realized PnL + UnPnL realizado. A healthy grid bot typically shows growing PnL realizado that eventually offsets any unrealized losses.
Resumo
- PnL (Lucros e Perdas) comes in two forms: PnL realizado from closed trades is locked in, while PnL nao realizado from open positions fluctuates with o mercado.
- Net PnL must include all costs (trading fees, taxa de financiamentos) for an accurate picture, and ROI expresses your PnL as a percentage of initial capital.
- Grid bots build steady PnL realizado from completed TP cycles while PnL nao realizado fluctuates with price, making total PnL a chave metric to monitor.
Proximo Passo
An important concept for understanding your worst-case performance: What is Drawdown?
✨ Este artigo foi util?
Faca suas perguntas no Discord →