Tags: RSISMA

This strategy mainly uses the Relative Strength Index (RSI) to determine overbought and oversold conditions in the market, combined with the price above the 200-day Simple Moving Average (SMA) as a trend filter, to decide whether to enter a trade. The strategy constructs entry conditions through three RSI indicators. Only when the short-term RSI is below 35 and shows a downward trend for three consecutive periods, while the third-period RSI is below 60, and the current closing price is above the 200-day SMA, will it go long. The exit condition is when the RSI crosses above 50.

- Calculate the RSI indicator for the specified period
- Determine if the following entry conditions are met:
- Current RSI is below 35
- Current RSI is lower than the previous period RSI, previous period RSI is lower than the second previous period RSI, second previous period RSI is lower than the third previous period RSI
- The third previous period RSI is below 60
- Current closing price is above the 200-day SMA

- If all four conditions above are met simultaneously, open a long position
- During the holding period, if the RSI crosses above 50, close the position
- Repeat steps 2-4 for the next trade

- By using RSI to determine overbought and oversold conditions and entering positions in the oversold area, it can capture market reversal opportunities
- By constructing entry signals with three RSIs together, it reduces the probability of false signals and improves signal reliability
- Adding the price above the 200-day moving average as a trend condition avoids trading in a downtrend
- The exit condition is simple and clear, allowing for timely profit realization
- The strategy logic is clear and easy to understand and implement

- The RSI indicator has a signal lag, which may miss the best entry timing
- The entry conditions are relatively strict, resulting in low trading frequency and potentially missing some market movements
- It may not perform well in choppy markets, getting caught in frequent entries and exits
- The strategy can only capture unilateral uptrends and cannot grasp downtrends after trend reversals

- Consider adding a trailing stop or fixed stop loss to control single trade risk
- Study the combination of RSI with other auxiliary indicators to improve the reliability and timeliness of entry and exit signals
- Optimize entry conditions to improve trading frequency while ensuring signal reliability
- Introduce position management to dynamically adjust positions based on trend strength and volatility
- Consider combining short-term and medium-term to develop strategy versions suitable for different market conditions

This strategy constructs entry conditions through a triple RSI, combined with the price above the long-term moving average as a trend filter, to capture oversold reversal setups. The strategy logic is simple and clear, easy to implement and optimize. However, the strategy also has risks and shortcomings such as signal lag, low trading frequency, and only being able to capture unilateral market moves. It needs continuous debugging and improvement in actual application. By introducing stop loss and profit taking, position management, combining with other indicators and other methods, the stability and profitability of the strategy can be further improved.

/*backtest start: 2023-05-15 00:00:00 end: 2024-05-14 00:00:00 period: 1d basePeriod: 1h exchanges: [{"eid":"Futures_Binance","currency":"BTC_USDT"}] */ //@version=5 //@author Honestcowboy // strategy("Triple RSI [Honestcowboy]" ) // $$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$ >> // ---------> User Inputs <----------- >> // $$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$ >> rsiLengthInput = input.int(5, minval=1, title="RSI Length", group="RSI Settings") rsiSourceInput = input.source(close, "Source", group="RSI Settings") // $$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$ >> // ---------> VARIABLE CALCULATIONS <----------- >> // $$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$ >> up = ta.rma(math.max(ta.change(rsiSourceInput), 0), rsiLengthInput) down = ta.rma(-math.min(ta.change(rsiSourceInput), 0), rsiLengthInput) rsi = down == 0 ? 100 : up == 0 ? 0 : 100 - (100 / (1 + up / down)) // $$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$ >> // ---------> CONDITIONALS <----------- >> // $$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$ >> rule1 = rsi<35 rule2 = rsi<rsi[1] and rsi[1]<rsi[2] and rsi[2]<rsi[3] rule3 = rsi[3]<60 rule4 = close>ta.sma(close, 200) longCondition = rule1 and rule2 and rule3 and rule4 closeCondition = rsi>50 // $$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$ >> // ---------> GRAPHICAL DISPLAY <----------- >> // $$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$ >> hline(30, title="Long Condition Line") hline(50, title="Exit Condition Line") plot(rsi) plotshape(longCondition ? rsi-3 : na, title="Long Condition", style=shape.triangleup, color=color.lime, location=location.absolute) plotshape(closeCondition and rsi[1]<50? rsi+3 : na, title="Exit Condition", style=shape.triangledown, color=#e60000, location=location.absolute) // $$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$ >> // ---------> AUTOMATION AND BACKTESTING <----------- >> // $$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$ >> if longCondition and strategy.position_size==0 strategy.entry("LONG", strategy.long) if closeCondition strategy.close("LONG")

- RSI2 Strategy Intraday Reversal Win Rate Backtest
- Relative Strength Index Mean Reversion Strategy
- Intraday BUY/SELL
- Bollinger Bands RSI Trading Strategy
- SWING TRADE SIGNALS
- RSI Dual-Side Trading Strategy
- QQE MOD + SSL Hybrid + Waddah Attar Explosion
- RSI and Bollinger Bands Double Strategy
- MOST Indicator Dual Position Adaptive Strategy
- Multi-Indicator Quantitative Trading Strategy - Super Indicator 7-in-1 Strategy

- CCI+RSI+KC Trend Filter Bi-Directional Trading Strategy
- BMSB Breakout Strategy
- SR Breakout Strategy
- Bollinger Bands Dynamic Breakout Strategy
- 8小时 ema
- RSI Quantitative Trading Strategy
- Bollinger Band ATR Trend Following Strategy
- Delta Volume with Fibonacci Levels Trading Strategy
- Dual RSI Differential Strategy
- Crypto Big Move Stochastic RSI Strategy
- Dual MACD Optimization Strategy Combining Trend Following and Momentum Trading
- Trading Strategy Based on Three Consecutive Bearish Candles and Dual Moving Averages
- DZ Session Breakout Strategy
- Han Yue - Trend Following Trading Strategy Based on Multiple EMAs, ATR and RSI
- 200 EMA, VWAP, MFI Trend Following Strategy
- EMA Cross Strategy with RSI Divergence, 30-Minute Trend Identification, and Price Exhaustion
- No Upper Wick Bullish Candle Breakout Strategy
- Relative Strength Index Mean Reversion Strategy
- BMSB Bollinger SuperTrend Trading Strategy
- EMA Dual Crossover Fixed Risk Stop Loss/Take Profit