ignore_roi_if_buy_signal -> ignore_roi_if_entry_signal

This commit is contained in:
Matthias
2022-04-05 20:20:51 +02:00
parent 5bafdb6108
commit b1378efdeb
17 changed files with 42 additions and 38 deletions

View File

@@ -93,7 +93,7 @@ class IStrategy(ABC, HyperStrategyMixin):
use_exit_signal: bool
exit_profit_only: bool
exit_profit_offset: float
ignore_roi_if_buy_signal: bool
ignore_roi_if_entry_signal: bool
# Position adjustment is disabled by default
position_adjustment_enable: bool = False
@@ -871,7 +871,7 @@ class IStrategy(ABC, HyperStrategyMixin):
current_profit = trade.calc_profit_ratio(current_rate)
# if enter signal and ignore_roi is set, we don't need to evaluate min_roi.
roi_reached = (not (enter and self.ignore_roi_if_buy_signal)
roi_reached = (not (enter and self.ignore_roi_if_entry_signal)
and self.min_roi_reached(trade=trade, current_profit=current_profit,
current_time=current_time))