Skip to content

Commit 1df5cd1

Browse files
committed
sell_stoploss: rework.
1 parent e320038 commit 1df5cd1

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

NostalgiaForInfinityNext.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2785,7 +2785,7 @@ def sell_under_min(self, current_profit: float, last_candle) -> tuple:
27852785
return False, None
27862786

27872787
def sell_stoploss(self, current_profit: float, last_candle, previous_candle_1, trade: 'Trade', current_time: 'datetime') -> tuple:
2788-
if (current_time - timedelta(minutes=1440) > trade.open_date_utc):
2788+
if (last_candle['sma_200_dec_24']) and (last_candle['ema_25'] < last_candle['ema_50']):
27892789
if (-0.12 <= current_profit < -0.08):
27902790
if (last_candle['close'] < last_candle['atr_high_thresh_1']) and (previous_candle_1['close'] > previous_candle_1['atr_high_thresh_1']):
27912791
return True, 'signal_stoploss_atr_1'

0 commit comments

Comments
 (0)