
এই কৌশলটি একটি প্রবণতা ট্র্যাকিং এবং গতিশীল ট্রেডিং সিস্টেম যা একাধিক প্রযুক্তিগত সূচকগুলির উপর ভিত্তি করে। এটি মূলত গড় প্রবণতা সূচক ((ADX), আপেক্ষিকভাবে শক্তিশালী সূচক ((RSI) এবং প্রকৃত তরঙ্গের ব্যাপ্তি ((ATR) এর সাথে মিলিত করে সম্ভাব্য একাধিক সুযোগ সনাক্ত করতে এবং এটিআর ব্যবহার করে গতিশীল লাভ এবং ক্ষতির দাম নির্ধারণ করতে। এই কৌশলটি বিশেষত 1 মিনিটের সময়কালের জন্য উপযুক্ত, কঠোর শর্তাবলী এবং ঝুঁকি পরিচালনার মাধ্যমে লেনদেনের সাফল্যের হার বাড়ানোর জন্য।
কৌশলটির মূল যুক্তিতে নিম্নলিখিত মূল উপাদানগুলি রয়েছে:
এই কৌশলটি একাধিক প্রযুক্তিগত সূচকের সমন্বিত প্রয়োগের মাধ্যমে একটি সম্পূর্ণ ট্রেডিং সিস্টেম তৈরি করে। এর সুবিধা হ’ল এটি প্রবণতা এবং গতিশীল বিশ্লেষণের সংমিশ্রণ এবং একটি গতিশীল ঝুঁকি ব্যবস্থাপনার পদ্ধতি গ্রহণ করে। যদিও কিছু ঝুঁকি রয়েছে, তবে যুক্তিসঙ্গত প্যারামিটার অপ্টিমাইজেশন এবং ঝুঁকি নিয়ন্ত্রণ ব্যবস্থা দ্বারা বাস্তব ব্যবসায়ের ক্ষেত্রে স্থিতিশীল পারফরম্যান্স অর্জন করা যায়। ব্যবসায়ীদের পরামর্শ দেওয়া হয় যে তারা রিয়েল-স্টোর ব্যবহারের আগে কৌশলটির যথাযথ প্রতিক্রিয়া এবং প্যারামিটার অপ্টিমাইজেশন এবং নির্দিষ্ট ট্রেডিং প্রজাতির বৈশিষ্ট্য অনুসারে যথাযথ সমন্বয় করা উচিত।
/*backtest
start: 2024-02-21 00:00:00
end: 2025-02-18 08:00:00
period: 1d
basePeriod: 1d
exchanges: [{"eid":"Binance","currency":"ETH_USDT"}]
*/
// This Pine Script™ code is subject to the terms of the Mozilla Public License 2.0 at https://mozilla.org/MPL/2.0/
// © SPcuttack
//@version=6
strategy("ADX & RSI Strategy with ATR Targets", overlay=true)
// Input parameters
adxLength = input.int(14, title="ADX Length")
adxSmoothing = input.int(14, title="ADX Smoothing")
rsiLength = input.int(14, title="RSI Length")
rsiSmaLength = input.int(20, title="RSI SMA Length")
atrLength = input.int(14, title="ATR Length")
atrMultiplierTarget = input.float(2.5, title="ATR Multiplier for Target")
atrMultiplierStop = input.float(1.5, title="ATR Multiplier for Stop Loss")
// ADX and DMI calculations
[adx, plusDI, minusDI] = ta.dmi(adxLength, adxSmoothing)
// RSI calculations
rsi = ta.rsi(close, rsiLength)
rsiSma = ta.sma(rsi, rsiSmaLength)
// ATR calculation
atr = ta.atr(atrLength)
// Slope calculations (difference from the previous value)
adxSlope = adx - adx[1]
rsiSlope = rsi - rsi[1]
// Entry conditions
adxCondition = adx > 18 and plusDI > minusDI and adxSlope > 0
rsiCondition = rsi > rsiSma and rsiSlope > 0
rsiCross60 = ta.crossover(rsi, 60)
// Global variable for long entry
var bool longEntry = false
if (adxCondition and rsiCondition and rsiCross60)
longEntry := true
else
longEntry := false
// Variables for target and stop loss levels
var float entryPrice = na
var float targetLevel = na
var float stopLossLevel = na
// Strategy actions
if (longEntry)
entryPrice := close
targetLevel := entryPrice + atr * atrMultiplierTarget
stopLossLevel := entryPrice - atr * atrMultiplierStop
strategy.entry("Long", strategy.long)
if (strategy.position_size > 0)
if (close >= targetLevel)
strategy.close("Long", comment="Tgt Hit")
if (close <= stopLossLevel)
strategy.close("Long", comment="SL Hit")
// Ensure lines plot on the chart body
targetLine = strategy.position_size > 0 ? targetLevel : na
stopLossLine = strategy.position_size > 0 ? stopLossLevel : na
plot(targetLine, title="Target Level", color=color.green, linewidth=2, offset=0)
plot(stopLossLine, title="Stop Loss Level", color=color.red, linewidth=2, offset=0)
// Add entry price for reference
plot(strategy.position_size > 0 ? entryPrice : na, title="Entry Price", color=color.blue, linewidth=1, style=plot.style_cross, offset=0)