Crypto trade MAE (maximum adverse excursion) measures the largest move against an entry while the position is open; MFE (maximum favorable excursion) measures the largest move in its favor. Calculate both from eligible prices between actual entry and exit, with direction, units and valuation rules stated. These within-trade measurements describe an observed path, not account drawdown, a guaranteed loss limit or profit that was necessarily executable.
A trade can close with a gain after a deep adverse move, or close with a loss after an earlier favorable move. The final result alone cannot distinguish those paths. The useful question is what happened while the recorded quantity was actually exposed.
Set the sign and units first
This worksheet reports MAE and MFE as nonnegative magnitudes. A signed adverse-return series would instead show negative values; do not compare the two conventions without translating them.
Let E be entry price, L the lowest eligible price and H the highest. Include the entry observation in the range. The price-distance calculations are:
| Direction | MAE magnitude | MFE magnitude |
|---|---|---|
| Long | max(0, E − L) | max(0, H − E) |
| Short | max(0, H − E) | max(0, E − L) |
The zero floor makes a favorable-only path's MAE zero. It also prevents a path that never moves favorably from acquiring a negative MFE. TradingView's adverse-excursion example illustrates the long entry-minus-low distance and entry-price percentage convention.
For a fixed quantity q in a linear instrument valued in quote currency, multiply each price distance by q to obtain gross currency excursion. An entry-relative percentage is distance divided by E, multiplied by 100. This guide uses that same entry denominator for shorts; it is not a return on margin.
Require E greater than zero for this percentage convention. If it is absent or invalid, preserve the currency calculation where meaningful and flag the percentage as unavailable. Inverse contracts, conversion rates and changing quantities require their own valuation. The linear versus inverse contract guide explains why one price-distance formula cannot value every derivative.
Build an eligibility ledger before taking extrema
Here is an original hypothetical long position in a fictional asset. Four units fill at 100 USDT at 10:00 UTC and all four exit at 104 at 10:10. Assume the listed observations contain the relevant extrema over the holding interval. Fees and financing are excluded.
| Observation | Price, USDT | Eligible for this trade? |
|---|---|---|
| 09:59, before entry | 92 | No |
| 10:00, entry fill | 100 | Yes |
| 10:01, while held | 98 | Yes |
| 10:04, while held | 109 | Yes |
| 10:07, while held | 96 | Yes |
| 10:10, exit fill | 104 | Yes |
| 10:11, after exit | 112 | No |
The eligible low is 96 and high is 109. Using 92 would turn the long's MAE from 4 to 8 USDT per unit. Using 112 would turn MFE from 9 to 12. Neither change reveals greater precision: both introduce prices outside the trade.
Candle boundaries need special care. If an entry fills at a candle's close, its earlier low did not occur during the position. If an exit fills at the next candle's open, later highs on that candle do not belong to it. An entry and exit sharing a timestamp may still require event sequence identifiers to resolve which observations came between them.
NinjaTrader's statistics documentation distinguishes recorded real-time extrema from bar-high/low backtest inputs and notes that missing real-time updates cannot contribute observations. This is a platform-specific implementation example, not a claim about KLINEO reporting.
If only completed candle closes are available, label the result close-sampled excursion. Do not present it as the maximum reached between observations. For partial boundary candles or competing events within a candle, use the intrabar-data evidence guide to separate finer evidence from an assumed path.
Compare long and short without changing the denominator
The long below uses that ledger. The independent hypothetical short also enters at 100 with four units, but reaches an eligible high of 103 and low of 91 before exiting at 98. Both use a fictional initial planned price-risk distance of 5 per unit, giving a fixed 20-USDT risk reference. This reference is not a promised maximum loss.
| Measurement | Long example | Short example |
|---|---|---|
| MAE, price distance | 4 | 3 |
| MFE, price distance | 9 | 9 |
| MAE, entry-relative | 4% | 3% |
| MFE, entry-relative | 9% | 9% |
| Gross MAE, USDT | 16 | 12 |
| Gross MFE, USDT | 36 | 36 |
| Final gross P&L, USDT | +16 | +8 |
| MAE / initial risk | 0.8R | 0.6R |
| MFE / initial risk | 1.8R | 1.8R |
For the short, adverse distance is 103 − 100 = 3, favorable distance is 100 − 91 = 9, and final gross profit is 4 × (100 − 98) = 8. The long's final gross profit is 4 × (104 − 100) = 16.
The long also falls from 109 to 96 while held: a 13-USDT decline per unit from its interim peak. Its MAE remains 4 per unit because MAE is anchored to entry. Calling the peak-to-trough decline MAE would mix two reference points.
Keep the original risk denominator if a stop later moves. With zero or undefined initial risk, an R multiple is undefined; currency excursion can still be reported. The risk–reward worksheet covers the planned pretrade amounts, which remain separate from these observed extrema.
A partial exit changes the currency path
Modify the long: two of its four units sell at 105 before the remaining two reach 109. The realized gross profit is 10 USDT. At 109, the remaining position has 18 of unrealized profit, so the campaign's combined marked gross P&L is 28.
Multiplying the nine-USDT favorable price distance by the original four units would show 36, overstating that campaign value. Multiplying by the final two units would show 18, omitting realized profit. With this altered schedule, the last two units exiting at 104 produce a final gross result of 18.
For variable size, reconstruct realized P&L plus the remaining position's marked P&L at each eligible event, then take extrema of that explicitly defined campaign series relative to zero at inception. Keep this label distinct from per-lot excursion or the remaining position's unrealized excursion. Add fees and financing at their actual modeled or recorded times if reporting net values. Realized versus unrealized P&L supplies the accounting distinction.
Use excursion to propose a test, not rewrite history
A large MFE followed by a small result suggests an exit question worth studying. It does not prove that the whole position could have sold at the high. Quotes, spread, available depth, order timing and price-source choice can change executable value.
Nor does a winning trade's small MAE establish a safe stop. Winners selected after completion exclude trades a tighter stop might have closed early. Changing the stop also changes holding intervals, later entries and the observations available for MFE. Replay a proposed rule on a separate evaluation sample rather than treating historical extrema as guaranteed alternative fills. TradingView's broker-emulator documentation makes explicit that historical OHLC fills depend on intrabar assumptions.
When summarizing many trades, keep excursion distributions separate from completed-return distributions. The skewness and kurtosis guide addresses the latter's asymmetry and tail estimates. Benchmark beta and alpha require synchronized return observations; substituting per-trade MAE or MFE would answer a different question. Account-level peak-to-trough loss belongs in the maximum-drawdown calculation.
Method and limits
This AI-assisted guide combines the cited primary software documentation with original hypothetical ledgers. Price, currency and R arithmetic were recomputed. No market sample, live execution, KLINEO performance or built-in excursion feature was evaluated. Preserve the trade grouping, entry/exit sequence, price source, sampling gaps, quantity history, cost convention and open-trade policy so another reviewer can reproduce the measurement.
