কৌশল অনুসরণ করে ডুয়াল এটিআর চ্যানেল ট্রেন্ড

লেখক:চাওঝাং, তারিখ: ২০২৩-১১-০১ ১১ঃ৪০ঃ০৭
ট্যাগঃ

img

সারসংক্ষেপ

ডাবল এটিআর চ্যানেল ট্রেন্ড অনুসরণ কৌশল একটি ট্রেন্ড ট্র্যাকিং কৌশল যা প্রবণতা প্রতিষ্ঠিত হওয়ার পরে প্রবণতা অনুসরণ করার জন্য চলমান গড়, এটিআর চ্যানেল এবং একাধিক প্রযুক্তিগত সূচককে একত্রিত করে।

এটি কিভাবে কাজ করে

কৌশলটি প্রবণতা দিক নির্ধারণের জন্য মূল চলমান গড় সূচক হিসাবে কিজুন লাইন ব্যবহার করে। এটি মূল্যের ক্রিয়াকলাপের পরিসীমা সীমাবদ্ধ করার জন্য এটিআর চ্যানেলগুলিও অন্তর্ভুক্ত করে - যখন দাম উপরের ব্যান্ডের কাছাকাছি থাকে তখন দীর্ঘ না যায় এবং যখন দাম নিম্ন ব্যান্ডের কাছাকাছি থাকে তখন নতুন উচ্চতা এবং বিক্রয় নিম্নতা এড়াতে শর্ট হয় না।

যখন কিজুন লাইনে একটি আপসোর্ড ক্রসওভার থাকে, তখন একটি ক্রয় সংকেত তৈরি হয়। যখন একটি ডাউনসোর্ড ক্রসওভার ঘটে, তখন একটি বিক্রয় সংকেত ট্রিগার হয়। মিথ্যা সংকেতগুলি ফিল্টার করার জন্য, কৌশলটি অ্যারন, আরএসআই, এমএসিডি এবং পিএসএআর সহ নিশ্চিতকরণের জন্য একাধিক প্রযুক্তিগত সূচকও ব্যবহার করে। সমস্ত নিশ্চিতকরণের শর্ত পূরণ হলেই একটি ক্রয় বা বিক্রয় সংকেত ট্রিগার হয়।

ট্রেডে একবার, কৌশলটি অবস্থানগুলি পরিচালনা করতে স্টপ লস এবং লাভ গ্রহণ করে। স্টপ লস 0.5 ATR এ সেট করা হয় এবং 0.5% এ লাভ গ্রহণ করা হয়। যখন দাম আবার বিপরীত দিকের কিজুন লাইনটি অতিক্রম করে, তখন অবস্থানটি অবিলম্বে বন্ধ হয়ে যাবে।

সুবিধা

  • প্রবণতা নির্ধারণের জন্য কিজুন লাইন ব্যবহার করে ব্যাপ্তি-সীমাবদ্ধ বাজার দ্বারা চড় মারতে এড়ানো হয়
  • ATR চ্যানেলগুলি ঝুঁকি নিয়ন্ত্রণের জন্য মূল্য কার্যকলাপকে সীমাবদ্ধ করে
  • একাধিক নিশ্চিতকরণ ব্যাপকভাবে মিথ্যা সংকেত হ্রাস করে
  • ঝুঁকি পরিচালনার সময় লাভের মধ্যে স্টপ লস এবং লাভের লক অন্তর্ভুক্ত করা

ঝুঁকি

  • একাধিক নিশ্চিতকরণ থেকে বিলম্বিত সংকেত, সম্ভবত প্রাথমিক প্রবণতা সরানো অনুপস্থিত
  • ছোট স্টপ লস প্রায়শই বন্ধ হয়ে যেতে পারে
  • খারাপ কিজুন এবং এটিআর পরামিতি অনেক ভুল সংকেত উৎপন্ন করতে পারে
  • প্যারামিটার অপ্টিমাইজেশান এবং বক্ররেখা ফিটিং উপর নির্ভর, লাইভ ট্রেডিং ভাল কাজ করতে পারে না

উন্নতির সুযোগ

  • ইচিমোকু মেঘের মত আরো উন্নত প্রবণতা সূচক পরীক্ষা করুন
  • আরও ভাল ঝুঁকি পুরস্কার অনুপাতের জন্য স্টপ লস এবং লাভের পয়েন্টগুলি অপ্টিমাইজ করুন
  • বিভিন্ন বাজারের জন্য সর্বোত্তম পরামিতি খুঁজুন
  • লাইভ মার্কেটের অবস্থার উপর ভিত্তি করে পরামিতিগুলির গতিশীল সমন্বয় যোগ করুন
  • নিশ্চিতকরণ সূচকগুলির বিভিন্ন সংমিশ্রণ পরীক্ষা করুন
  • কৌশলটির দৃঢ়তা নিশ্চিত করার জন্য ক্রমাগত অপ্টিমাইজ করুন

সিদ্ধান্ত

ডুয়াল এটিআর চ্যানেল ট্রেন্ড অনুসরণকারী কৌশলটি একবারে প্রবণতার দিকে ট্রেড করার জন্য চলমান গড়, এটিআর চ্যানেল এবং একাধিক প্রযুক্তিগত সূচককে একত্রিত করে। একক সূচক কৌশলগুলির তুলনায়, এটি সংকেতের গুণমান এবং জয়ের হারকে ব্যাপকভাবে উন্নত করতে পারে। স্টপ লস এবং লাভ গ্রহণের প্রক্রিয়াগুলি ঝুঁকি নিয়ন্ত্রণ করে। প্যারামিটার অপ্টিমাইজেশন এবং সংমিশ্রণ পরীক্ষার মাধ্যমে এই কৌশলটির স্থিতিশীল মুনাফা অর্জনের সম্ভাবনা রয়েছে। তবে historicalতিহাসিক ডেটাতে এর নির্ভরতা উদ্বেগজনক এবং লাইভ পারফরম্যান্সের আরও যাচাইয়ের প্রয়োজন। স্থিতিশীলতা নিশ্চিত করার জন্য অবিচ্ছিন্ন অপ্টিমাইজেশন মূল।


/*backtest
start: 2023-10-24 00:00:00
end: 2023-10-27 00:00:00
period: 15m
basePeriod: 5m
exchanges: [{"eid":"Futures_Binance","currency":"BTC_USDT"}]
*/

//@version=4
// strategy(title="NoNonsense Forex", overlay=true, default_qty_value=100000, initial_capital=100)

//////////////////////
////// BASELINE //////
//////////////////////
ma_slow_type = input(title="Baseline Type", type=input.string, defval="Kijun", options=["ALMA", "EMA", "DEMA", "TEMA", "WMA", "VWMA", "SMA", "SMMA", "HMA", "LSMA", "Kijun", "McGinley"])
ma_slow_src = close //input(title="MA Source", type=input.source, defval=close)
ma_slow_len = input(title="Baseline Length", type=input.integer, defval=20)
ma_slow_len_fast = input(title="Baseline Length Fast", type=input.integer, defval=12)

lsma_offset  = input(defval=0, title="* Least Squares (LSMA) Only - Offset Value", minval=0)
alma_offset  = input(defval=0.85, title="* Arnaud Legoux (ALMA) Only - Offset Value", minval=0, step=0.01)
alma_sigma   = input(defval=6, title="* Arnaud Legoux (ALMA) Only - Sigma Value", minval=0)

ma(type, src, len) =>
    float result = 0
    if type=="SMA" // Simple
        result := sma(src, len)
    if type=="EMA" // Exponential
        result := ema(src, len)
    if type=="DEMA" // Double Exponential
        e = ema(src, len)
        result := 2 * e - ema(e, len)
    if type=="TEMA" // Triple Exponential
        e = ema(src, len)
        result := 3 * (e - ema(e, len)) + ema(ema(e, len), len)
    if type=="WMA" // Weighted
        result := wma(src, len)
    if type=="VWMA" // Volume Weighted
        result := vwma(src, len) 
    if type=="SMMA" // Smoothed
        w = wma(src, len)
        result := na(w[1]) ? sma(src, len) : (w[1] * (len - 1) + src) / len
    if type=="HMA" // Hull
        result := wma(2 * wma(src, len / 2) - wma(src, len), round(sqrt(len)))
    if type=="LSMA" // Least Squares
        result := linreg(src, len, lsma_offset)
    if type=="ALMA" // Arnaud Legoux
        result := alma(src, len, alma_offset, alma_sigma)
    if type=="Kijun" //Kijun-sen
        kijun = avg(lowest(len), highest(len))
        result :=kijun
    if type=="McGinley"
        mg = 0.0
        mg := na(mg[1]) ? ema(src, len) : mg[1] + (src - mg[1]) / (len * pow(src/mg[1], 4))
        result :=mg
    result

baseline = ma(ma_slow_type, ma_slow_src, ma_slow_len)
plot(baseline, title='Baseline', color=rising(baseline,1) ? color.green : falling(baseline,1) ? color.maroon : na, linewidth=3)

//////////////////
////// ATR ///////
//////////////////
atrlength=input(14, title="ATR Length")
one_atr=rma(tr(true), atrlength)
upper_atr_band=baseline+one_atr
lower_atr_band=baseline-one_atr
plot(upper_atr_band, color=color.gray, style=plot.style_areabr, transp=95, histbase=50000, title='ATR Cave')
plot(lower_atr_band, color=color.gray, style=plot.style_areabr, transp=95, histbase=0, title='ATR Cave')
plot(upper_atr_band, color=close>upper_atr_band ? color.fuchsia : na, style=plot.style_line, linewidth=5, transp=50, title='Close above ATR cave')
plot(lower_atr_band, color=close<lower_atr_band ? color.fuchsia : na, style=plot.style_line, linewidth=5, transp=50, title='Close below ATR cave')
donttradeoutside_atrcave=input(true)
too_high = close>upper_atr_band and donttradeoutside_atrcave
too_low = close<lower_atr_band and donttradeoutside_atrcave

////////////////////////////
////// CONFIRMATION 1 ////// the trigger actually
////////////////////////////
lenaroon = input(8, minval=1, title="Length Aroon")
c1upper = 100 * (highestbars(high, lenaroon+1) + lenaroon)/lenaroon
c1lower = 100 * (lowestbars(low, lenaroon+1) + lenaroon)/lenaroon
c1CrossUp=crossover(c1upper,c1lower)
c1CrossDown=crossunder(c1upper,c1lower)


////////////////////////////////
////// CONFIRMATION: MACD //////
////////////////////////////////
dont_use_macd=input(false)
macd_fast_length = input(title="Fast Length", type=input.integer, defval=13)
macd_slow_length = input(title="Slow Length", type=input.integer, defval=26)
macd_signal_length = input(title="Signal Smoothing", type=input.integer, minval = 1, maxval = 50, defval = 9)
macd_fast_ma = ema(close, macd_fast_length)
macd_slow_ma = ema(close, macd_slow_length)
macd = macd_fast_ma - macd_slow_ma
macd_signal = ema(macd, macd_signal_length)
macd_hist = macd - macd_signal

macdLong=macd_hist>0 or dont_use_macd
macdShort=macd_hist<0 or dont_use_macd

/////////////////////////////
///// CONFIRMATION: RSI /////
/////////////////////////////
dont_use_rsi=input(false)
lenrsi = input(14, minval=1, title="RSI Length") //14
up = rma(max(change(close), 0), lenrsi)
down = rma(-min(change(close), 0), lenrsi)
rsi = down == 0 ? 100 : up == 0 ? 0 : 100 - (100 / (1 + up / down))
rsiLong=rsi>50 or dont_use_rsi
rsiShort=rsi<50 or dont_use_rsi

//////////////////////////////
///// CONFIRMATION: PSAR /////
//////////////////////////////
dont_use_psar=input(false)
psar_start = input(0.03, step=0.01)
psar_increment = input(0.018, step=0.001)
psar_maximum = input(0.11, step=0.01) //default 0.08
psar = sar(psar_start, psar_increment, psar_maximum)

plot(psar, style=plot.style_cross, color=color.blue, title='PSAR')
psarLong=close>psar or dont_use_psar
psarShort=close<psar or dont_use_psar

/////////////////////////
///// CONFIRMATIONS /////
/////////////////////////
Long_Confirmations=psarLong and rsiLong and macdLong
Short_Confirmations=psarShort and rsiShort and macdShort

GoLong=c1CrossUp and Long_Confirmations and not too_high
GoShort=c1CrossDown and Short_Confirmations and not too_low

////////////////////
///// STRATEGY /////
////////////////////

use_exit=input(false)
KillLong=c1CrossDown and use_exit
KillShort=c1CrossUp and use_exit

SL=input(0.5, step=0.1)/syminfo.mintick
TP=input(0.005, step=0.001)/syminfo.mintick

strategy.entry("nnL", strategy.long, when = GoLong)
strategy.entry("nnS", strategy.short, when = GoShort)
strategy.exit("XL-nn", from_entry = "nnL", loss = SL, profit=TP)
strategy.exit("XS-nn", from_entry = "nnS", loss = SL, profit=TP)
strategy.close("nnL", when = KillLong)
strategy.close("nnS", when = KillShort)



আরো