
এই কৌশলটি একটি মোমেন্টাম রিভার্সাল ট্রেডিং সিস্টেম যা RSI এবং বলিঞ্জার ব্যান্ডের দ্বৈত প্রযুক্তিগত সূচকগুলিকে একত্রিত করে অতিরিক্ত কেনা এবং অতিবিক্রীত এলাকা চিহ্নিত করে বাণিজ্য করার জন্য। কৌশলটি 1:2-এর ঝুঁকি-থেকে-সুবিধা অনুপাত গ্রহণ করে এবং ঝুঁকি নিয়ন্ত্রণের জন্য ট্রেলিং স্টপ লসকে একত্রিত করে। মূল যুক্তি হল যখন RSI এবং বলিঞ্জার ব্যান্ড একই সময়ে অতিরিক্ত কেনা বা বেশি বিক্রি হওয়া সংকেত দেখা যায় তখন ট্রেড করা এবং কঠোর ঝুঁকি ব্যবস্থাপনার মাধ্যমে তহবিল রক্ষা করা।
কৌশলটি 14-পিরিয়ড RSI এবং 20-পিরিয়ড বলিঙ্গার ব্যান্ডগুলিকে প্রধান সূচক হিসাবে ব্যবহার করে। কেনার শর্ত একই সময়ে পূরণ করতে হবে: RSI 30 এর নিচে (অতি বিক্রিত) এবং দাম নিম্ন বলিংগার ব্যান্ড ট্র্যাকের ছোঁয়া বা নীচে। বিক্রির শর্ত একই সময়ে পূরণ করতে হবে: RSI 70 এর উপরে (অতি কেনা) এবং দাম উপরের বলিঙ্গার ব্যান্ডের উপরে বা ছুঁয়েছে। সিস্টেমটি চলমান স্টপ লস হিসাবে 5 K লাইনের সর্বোচ্চ/সর্বনিম্ন পয়েন্ট ব্যবহার করে এবং স্টপ লাভের অবস্থান স্টপ লসের দূরত্বের দ্বিগুণ, এবং 1:2 এর ঝুঁকি-সুবিধা অনুপাত কঠোরভাবে প্রয়োগ করে।
এটি একটি সম্পূর্ণ কাঠামোগত বিপরীতমুখী ট্রেডিং কৌশল যা সঠিকতা উন্নত করতে দ্বৈত প্রযুক্তিগত সূচক ব্যবহার করে এবং কঠোর ঝুঁকি ব্যবস্থাপনা নিযুক্ত করে। যদিও কৌশলটি সহজ এবং স্বজ্ঞাত, এটি একটি পরিপক্ক ট্রেডিং সিস্টেমের জন্য প্রয়োজনীয় মূল উপাদানগুলি ধারণ করে। প্রস্তাবিত অপ্টিমাইজেশন দিকনির্দেশের মাধ্যমে এই কৌশলটির আরও উন্নতির জন্য জায়গা রয়েছে। প্রকৃত ট্রেডিংয়ে, প্রথমে পর্যাপ্ত ব্যাকটেস্টিং এবং প্যারামিটার অপ্টিমাইজেশন পরিচালনা করার পরামর্শ দেওয়া হয়।
/*backtest
start: 2024-12-06 00:00:00
end: 2025-01-04 08:00:00
period: 3h
basePeriod: 3h
exchanges: [{"eid":"Futures_Binance","currency":"BTC_USDT"}]
*/
//@version=5
strategy("RSI + Bollinger Bands with 1:2 Risk/Reward", overlay=true)
// Define Inputs
length_rsi = input.int(14, title="RSI Period")
oversold_level = input.int(30, title="RSI Oversold Level")
overbought_level = input.int(70, title="RSI Overbought Level")
length_bb = input.int(20, title="Bollinger Bands Period")
src = close
risk_to_reward = input.float(2.0, title="Risk-to-Reward Ratio", minval=1.0, step=0.1)
// Calculate Indicators
rsi_value = ta.rsi(src, length_rsi)
basis = ta.sma(src, length_bb)
dev = ta.stdev(src, length_bb)
upper_band = basis + 2 * dev
lower_band = basis - 2 * dev
// Define Buy and Sell Conditions
rsi_buy_condition = rsi_value < oversold_level // RSI below 30 (buy signal)
bollinger_buy_condition = close <= lower_band // Price at or near lower Bollinger Band (buy signal)
rsi_sell_condition = rsi_value > overbought_level // RSI above 70 (sell signal)
bollinger_sell_condition = close >= upper_band // Price at or near upper Bollinger Band (sell signal)
// Combine Buy and Sell Conditions
buy_condition = rsi_buy_condition and bollinger_buy_condition
sell_condition = rsi_sell_condition and bollinger_sell_condition
// Plot Buy and Sell Signals with white text and green/red boxes
plotshape(series=buy_condition, location=location.belowbar, color=color.green, style=shape.labelup, title="Buy Signal", text="BUY", textcolor=color.white, size=size.small)
plotshape(series=sell_condition, location=location.abovebar, color=color.red, style=shape.labeldown, title="Sell Signal", text="SELL", textcolor=color.white, size=size.small)
// Calculate Swing Points (for Stop Loss)
swing_low = ta.lowest(low, 5) // Last 5 bars' low
swing_high = ta.highest(high, 5) // Last 5 bars' high
// Calculate Risk (Distance from Entry to SL)
long_risk = close - swing_low
short_risk = swing_high - close
// Calculate Take Profit using 1:2 Risk-to-Reward Ratio
take_profit_long = close + 2 * long_risk
take_profit_short = close - 2 * short_risk
// Strategy Execution: Enter Buy/Sell Positions
if buy_condition
strategy.entry("Buy", strategy.long)
strategy.exit("Take Profit", "Buy", limit=take_profit_long, stop=swing_low) // Set TP and SL for Buy
if sell_condition
strategy.entry("Sell", strategy.short)
strategy.exit("Take Profit", "Sell", limit=take_profit_short, stop=swing_high) // Set TP and SL for Sell
// Plotting the Indicators for Visualization (Optional - comment out if not needed)
plot(rsi_value, color=color.blue, title="RSI", linewidth=2, display=display.none)
plot(upper_band, color=color.red, title="Upper BB", display=display.none)
plot(lower_band, color=color.green, title="Lower BB", display=display.none)