This strategy combines the RSI indicator with price breakthroughs to find rotation opportunities within a certain trend and range-bound market, so as to make short-term trades and pursue highly efficient short-term profits.
Therefore, this strategy integrates multiple dimensions of judgment logic to conduct short-term profitable rotation operations utilizing the buy and sell signals generated by RSI indicator, under certain trends and breakthrough chances. It can effectively seize the reversal bounce opportunity when the market is extremely oversold, as well as the retracement chance when extremely overbought in the short term.
This strategy leverages RSI indicator to identify short-term reversal opportunities from extremely overbought/oversold scenarios, and conducts short-term profitable rotation operations combined with price breakthroughs. Its characteristics are pursuing short-term efficiency, easy operation, limited risks, and hence extremely suitable for short-term traders to use under certain market conditions. Attention should be paid to judging the overall major trend, parameter optimization etc., in order to obtain better performance.
/*backtest start: 2024-01-01 00:00:00 end: 2024-01-31 23:59:59 period: 1h basePeriod: 15m exchanges: [{"eid":"Futures_Binance","currency":"BTC_USDT"}] */ // This source code is subject to the terms of the Mozilla Public License 2.0 at https://mozilla.org/MPL/2.0/ // © relevantLeader16058 //@version=4 strategy(shorttitle='RSI Classic Strategy',title='RSI Classic Strategy (by Coinrule)', overlay=true, initial_capital = 1000, process_orders_on_close=true, default_qty_type = strategy.percent_of_equity, default_qty_value = 30, commission_type=strategy.commission.percent, commission_value=0.1) //Backtest dates fromMonth = input(defval = 1, title = "From Month", type = input.integer, minval = 1, maxval = 12) fromDay = input(defval = 1, title = "From Day", type = input.integer, minval = 1, maxval = 31) fromYear = input(defval = 2020, title = "From Year", type = input.integer, minval = 1970) thruMonth = input(defval = 1, title = "Thru Month", type = input.integer, minval = 1, maxval = 12) thruDay = input(defval = 1, title = "Thru Day", type = input.integer, minval = 1, maxval = 31) thruYear = input(defval = 2112, title = "Thru Year", type = input.integer, minval = 1970) showDate = input(defval = true, title = "Show Date Range", type = input.bool) start = timestamp(fromYear, fromMonth, fromDay, 00, 00) // backtest start window finish = timestamp(thruYear, thruMonth, thruDay, 23, 59) // backtest finish window window() => true // RSI inputs and calculations lengthRSI = 14 RSI = rsi(close, lengthRSI) oversold= input(30) overbought= input(60) //Entry strategy.entry(id="long", long = true, when = RSI< oversold and window()) //Exit //RSI strategy.close("long", when = RSI > overbought and window())template: strategy.tpl:40:21: executing "strategy.tpl" at <.api.GetStrategyListByName>: wrong number of args for GetStrategyListByName: want 7 got 6