Improve docstring

This commit is contained in:
Matthias 2020-12-19 13:18:06 +01:00
parent b2c1098316
commit 6892c08e9b
1 changed files with 3 additions and 1 deletions

View File

@ -258,12 +258,14 @@ class IStrategy(ABC):
def stoploss_value(self, pair: str, trade: Trade, current_time: datetime, current_rate: float,
current_profit: float, **kwargs) -> float:
"""
Define custom stoploss logic
Custom stoploss logic, returning the new distance relative to current_rate (as ratio).
e.g. returning -0.05 would create a stoploss 5% below current_rate.
The custom stoploss can never be below self.stoploss, which serves as a hard maximum loss.
For full documentation please go to https://www.freqtrade.io/en/latest/strategy-advanced/
When not implemented by a strategy, returns the initial stoploss value
Only called when custom_stoploss is set to True.
:param pair: Pair that's about to be sold.
:param trade: trade object.