Documentation for liquidation_buffer

This commit is contained in:
Sam Germain 2022-02-10 21:02:05 -06:00 committed by Matthias
parent e5d68f12d2
commit 305d3738d9

View File

@ -15,7 +15,7 @@
## Understand `trading_mode` ## Understand `trading_mode`
The possible values are: `spot` (default), `margin`(*coming soon*) or `futures`. The possible values are: `spot` (default), `margin`(*Currently unavailable*) or `futures`.
### Spot ### Spot
@ -69,6 +69,18 @@ One account is used to share collateral between markets (trading pairs). Margin
"margin_mode": "cross" "margin_mode": "cross"
``` ```
## Understand `liquidation_buffer`
*Defaults to `0.05`.*
A ratio specifying how large of a safety net to place between the liquidation price and the stoploss to prevent a position from reaching the liquidation price
Possible values are any floats between 0.0 and 0.99
**ex:** If a trade is entered at a price of 10 coin/USDT, and the liquidation price of this trade is 8 coin/USDT, then with `liquidation_buffer` set to `0.05` the minimum stoploss for this trade would be 8 + ((10 - 8) * 0.05) = 8 + 0.1 = 8.1
!!! Danger "A `liquidation_buffer` of 0.0, or a low `liquidation_buffer` is likely to result in liquidations, and liquidation fees"
Currently Freqtrade is able to calculate liquidation prices, but does not calculate liquidation fees. Setting your `liquidation_buffer` to 0.0, or using a low `liquidation_buffer` could result in your positions being liquidated. Freqtrade does not track liquidation fees, so liquidations will result in accurate profit/loss results for your bot. If you use a low `liquidation_buffer`, it is recommended to use `stoploss_on_exchange`.
### Developer ### Developer
#### Margin mode #### Margin mode
@ -82,3 +94,4 @@ All Fees are included in `current_profit` calculations during the trade.
#### FUTURES MODE #### FUTURES MODE
Funding fees are either added or subtracted from the total amount of a trade Funding fees are either added or subtracted from the total amount of a trade