Skip to content

Commit

Permalink
X4: add global buy protection rule.
Browse files Browse the repository at this point in the history
  • Loading branch information
iterativv committed Oct 14, 2023
1 parent e155c63 commit ed18089
Showing 1 changed file with 15 additions and 1 deletion.
16 changes: 15 additions & 1 deletion NostalgiaForInfinityX4.py
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,7 @@ class NostalgiaForInfinityX4(IStrategy):
INTERFACE_VERSION = 3

def version(self) -> str:
return "v14.0.333"
return "v14.0.334"

# ROI table:
minimal_roi = {
Expand Down Expand Up @@ -6564,6 +6564,20 @@ def populate_indicators(self, dataframe: DataFrame, metadata: dict) -> DataFrame
| (dataframe['rsi_14_15m'] < 36.0)
| (dataframe['ema_200_dec_48_1h'] == False)
)
# 1h & 1d downtrend, 5m & 1d downmove, 15m still high, 1h & 4h & 1d downtrend
&
(
(dataframe['not_downtrend_1h'])
| (dataframe['not_downtrend_1d'])
| (dataframe['rsi_3'] > 12.0)
| (dataframe['close'] > dataframe['bb20_2_low_15m'])
| (dataframe['close'] > dataframe['bb20_2_low_1h'])
| (dataframe['rsi_3_1d'] > 12.0)
| (dataframe['rsi_14_15m'] < 36.0)
| (dataframe['ema_200_dec_48_1h'] == False)
| (dataframe['ema_200_dec_24_4h'] == False)
| (dataframe['ema_200_dec_4_1d'] == False)
)
)

tok = time.perf_counter()
Expand Down

0 comments on commit ed18089

Please sign in to comment.