Add stoploss or liquidation property

This commit is contained in:
Matthias
2022-07-30 08:12:48 +02:00
parent 4da96bc511
commit 845cecd38f
3 changed files with 19 additions and 8 deletions

View File

@@ -1063,13 +1063,6 @@ class IStrategy(ABC, HyperStrategyMixin):
f"stoploss is {trade.stop_loss:.6f}, "
f"initial stoploss was at {trade.initial_stop_loss:.6f}, "
f"trade opened at {trade.open_rate:.6f}")
new_stoploss = (
trade.stop_loss + trade.initial_stop_loss
if trade.is_short else
trade.stop_loss - trade.initial_stop_loss
)
logger.debug(f"{trade.pair} - Trailing stop saved "
f"{new_stoploss:.6f}")
return ExitCheckTuple(exit_type=exit_type)