Skip to content

Commit

Permalink
X5: add global protection rule (Long).
Browse files Browse the repository at this point in the history
  • Loading branch information
iterativv committed Feb 6, 2025
1 parent 821cc5a commit db311ca
Showing 1 changed file with 17 additions and 0 deletions.
17 changes: 17 additions & 0 deletions NostalgiaForInfinityX5.py
Original file line number Diff line number Diff line change
Expand Up @@ -8503,6 +8503,23 @@ def populate_indicators(self, df: DataFrame, metadata: dict) -> DataFrame:
| (df["ROC_9_1d"] > -10.0)
| (df["close"] > (df["high_max_12_1d"] * 0.50))
)
# 15m & 1h & & 4h & 1d down move, 15m & 1h still not low enough, 4h & 1d still not low enough & downtrend, drop in last 30d
& (
(df["RSI_3_15m"] > 45.0)
| (df["RSI_3_1h"] > 45.0)
| (df["RSI_3_4h"] > 45.0)
| (df["RSI_3_1d"] > 20.0)
| (df["RSI_14_15m"] < 20.0)
| (df["CCI_20_15m"] < -200.0)
| (df["RSI_14_1h"] < 20.0)
| (df["CCI_20_1h"] < -200.0)
| (df["RSI_14_4h"] < 20.0)
| (df["CCI_20_4h"] < -200.0)
| (df["ROC_9_4h"] > -15.0)
| (df["RSI_14_1d"] < 20.0)
| (df["ROC_9_1d"] > -30.0)
| (df["close"] > (df["high_max_30_1d"] * 0.25))
)
# 15m & 1h & 4h & 1d down move, 15m high, 1h still not low enough, 1d still high
& (
(df["RSI_3_15m"] > 40.0)
Expand Down

0 comments on commit db311ca

Please sign in to comment.