RSI W প্যাটার্ন ব্রেকআউট কৌশল

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

সারসংক্ষেপ

এই কৌশলটি RSI সূচকের উপর W প্যাটার্নগুলিকে ট্রেন্ডের শর্তগুলির সাথে সংযুক্ত করে কম-ক্রয়-উচ্চ-বিক্রয় ব্রেকআউট অপারেশনগুলি বাস্তবায়নের জন্য চিহ্নিত করে। অতিরিক্ত ক্রয় / অতিরিক্ত বিক্রয় স্তরের তুলনায়, W প্যাটার্ন সনাক্তকরণ আরও স্পষ্ট ক্রয় সংকেত সময় সরবরাহ করে।

কৌশলগত যুক্তি

  1. সম্ভাব্য ক্রয়ের সুযোগগুলি সনাক্ত করতে আরএসআই ((৫) ব্যবহার করে ডাব্লু প্যাটার্নগুলি সনাক্ত করুন। ওভারসোল্ড অঞ্চলে প্রদর্শিত ডাব্লু প্যাটার্নগুলি আসন্ন বিপরীতের ইঙ্গিত দেয়।

  2. EMA50 এর উপরে EMA20 এর ক্রসিং আপট্রেন্ড নির্ধারণ করে, যা দিকনির্দেশক পক্ষপাত প্রদান করে।

  3. যখন একটি W প্যাটার্ন চিহ্নিত করা হয় এবং প্রবণতা আপ হয়, দীর্ঘ আদেশ সক্রিয় করা হয়।

  4. যদি ইতিমধ্যে পজিশনে থাকেন, তাহলে আরএসআই আবার ২০ এর নিচে নামলে অতিরিক্ত ক্রয় করা যাবে।

  5. আরএসআই যখন ৭৫-এর উপরে চলে যায়, তখন তা বোঝায় যে, ওভার-কুপেড শর্ত রয়েছে, লাভের জন্য বেরিয়ে আসা শুরু হয়।

  6. ৮% স্টপ লস সেট করা আছে। যদি লস এই পয়েন্ট অতিক্রম করে, তাহলে স্টপ লস আউট ট্রিগার করা হবে।

সুবিধা বিশ্লেষণ

  1. ডাব্লু প্যাটার্ন সনাক্তকরণ প্রবেশের নিশ্চয়তা বৃদ্ধি করে।

  2. প্রবণতা ফিল্টারগুলির সাথে একত্রিত করা মিথ্যা সংকেত এবং বিপরীত সম্ভাবনাগুলি মিস করা এড়ায়।

  3. আরএসআই (৫) স্বল্পমেয়াদী সুযোগগুলি সময়মতো ধরতে পারে।

  4. লাভ গ্রহণ এবং স্টপ লস পয়েন্ট ঝুঁকি নিয়ন্ত্রণে সহায়তা করে।

ঝুঁকি বিশ্লেষণ

  1. ডাব্লু প্যাটার্ন স্বীকৃতি প্যারামিটার টিউনিং উপর নির্ভর করে, অনুপস্থিত বা ভুল সনাক্তকরণ গঠন ঝুঁকি বিদ্যমান।

  2. একটি বিপরীত সংকেত হিসাবে, ফাঁদে পড়ার ঝুঁকি বিদ্যমান।

  3. আরএসআই-তে ভুয়া ব্রেকআউটের প্রবণতা রয়েছে, তাই সঠিক সংকেত ফিল্টারিং প্রয়োজন।

  4. যদি স্টপ লস পয়েন্ট খুব বড় হয়, তাহলে অকাল স্টপ হতে পারে।

অপ্টিমাইজেশান নির্দেশাবলী

  1. সর্বোত্তম পরামিতি খুঁজে পেতে বিভিন্ন RSI সময় পরীক্ষা করুন।

  2. প্যাটার্ন স্বীকৃতির নির্ভুলতা বাড়ানোর জন্য আরও মানদণ্ড যুক্ত করুন।

  3. সিগন্যাল ফিল্টারিং এবং ভুল ট্রেড হ্রাস করার জন্য অন্যান্য সূচকগুলির সাথে একত্রিত করুন।

  4. স্টপ লস কৌশল অপ্টিমাইজ করার জন্য স্টপ লস স্তরগুলি গতিশীলভাবে সামঞ্জস্য করুন।

  5. লাভজনকতা নিশ্চিত করে ধরে রাখার সময় বাড়ানোর জন্য মুনাফা গ্রহণের কৌশলটি অনুকূল করা।

সংক্ষিপ্তসার

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


/*backtest
start: 2023-08-17 00:00:00
end: 2023-09-16 00:00:00
period: 3h
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/
// © mohanee

//@version=4
strategy(title="RSI W Pattern strategy", pyramiding=2, shorttitle="RSI W Pattern", overlay = false)

//Strategy Rules
//ema20 is above ema50
//RSI5 making W pattern in oversold area  or just below 70 level  , you can define the value for parameter buyRsiEntry --- dont go beyond 70
//Exit when RSI reaches 75 

len = input(title="RSI Period", minval=1, defval=5)
buyRsiEntry = input(title="look for W pattern bottom edges well below RSI level (BUY) ", minval=10, defval=65, maxval=70)
//numberOfBars = input(title="Number of Bars in W pattern ", minval=4, defval=4, maxval=6)

emaL = input(title="Long Term EMA", minval=1, defval=50, maxval=200)
emaS = input(title="Short Term EMA", minval=1, defval=20, maxval=200)

stopLoss = input(title="Stop Loss %", minval=1, defval=8, maxval=10)

//rsiWp1=false

myRsi = rsi(close,len)

//longEmaVal=ema(close,emaL)
//shortEmaVal=ema(close,emaS)

entryEma=ema(close,5)  // This is used as filetr for BUY


isEma20AboveEma50=ema(close,emaS)>ema(close,emaL) ? true : false 

//W Pattern
//rsiWp1 =  myRsi>myRsi[1] and myRsi>=30 and myRsi[1]<myRsi[2] and myRsi[2]>myRsi[3]  and myRsi[3]<myRsi[4] //This is published one
rsiWp1 =    myRsi>myRsi[1] and myRsi>=30 and myRsi[1]<myRsi[2] and myRsi[2]>myRsi[3]  and myRsi[3]<myRsi[4] and (low[1]<=low[4] or low[3]<=low[4] ) // looking for recent low

//rsiWp1 =  myRsi>myRsi[1] and myRsi>=30 and myRsi[1]<myRsi[2] and myRsi[2]>myRsi[3]  and myRsi[3]<myRsi[4]  //Ths one has 92% win rate and 4.593 prfit factor

//long condition filters
//1. ema20 > ema50
//2. Rsi5 has W pattern
//3. current RSI <= 65 (parameter buyRsiEntry)  (dont go beyond 70 , becuase that is already overbought area)
//4. current price low/close is below 5 ema --- looking for pullback  -- Optional
longCondition =  isEma20AboveEma50 and rsiWp1   and (myRsi<=buyRsiEntry  and myRsi>=30)  
//and (low<entryEma or close<entryEma)  --- if this optional required , add it to above condition

patternText=" W "

barcolor(longCondition?color.yellow:na)

//initial entry
strategy.entry("RSI_W_LE", comment="Buy" , long=true, when=longCondition  )

//legging in to existing 
strategy.entry("RSI_W_LE",comment="Add", long=true, when=strategy.position_size>0 and crossover(myRsi,10 ))

//calculate stoploss value
stopLossValue=strategy.position_avg_price -  (strategy.position_avg_price*stopLoss/100) 


rsiPlotColor=longCondition ?color.yellow:color.purple


plot(myRsi, title="RSI", linewidth=2, color=color.purple)
//    plot(myRsi, title="RSI", linewidth=2, color=rsiWp1?color.yellow:color.purple)
    //plot(myRsi[1], title="RSI", linewidth=2, color=rsiWp1==true?color.yellow:color.purple)
    //plot(myRsi[2], title="RSI", linewidth=2, color=rsiWp1?color.yellow:color.purple)
    //plot(myRsi[3], title="RSI", linewidth=2, color=rsiWp1?color.yellow:color.purple)
    //plot(myRsi[4], title="RSI", linewidth=2, color=rsiWp1?color.yellow:color.purple)
    


hline(40, title="Middle Line", color=color.blue, linestyle=hline.style_dashed)
obLevel = hline(75, title="Overbought", color=color.red, linestyle=hline.style_dashed)
osLevel = hline(30, title="Oversold", color=color.purple, linestyle=hline.style_dashed)
fill(obLevel, osLevel, title="Background", color=#9915FF, transp=90)


plotshape(
	 longCondition ? myRsi[1] : na,
	 offset=-1,
	 title="W Pattern",
	 text=patternText,
	 style=shape.labelup,
	 location=location.absolute,
	 color=color.purple,
	 textcolor=color.yellow,
	 transp=0
	 )	 
	 
bgcolor(strategy.position_size>0?color.green:na, transp=40, title='In Long Position')

//take profit or close when RSI reaches 75    
takeProfit=crossover(myRsi,75)

//close when RSi reaches profit level 
strategy.close("RSI_W_LE", comment="TP Exit", qty=strategy.position_size,when=crossover(myRsi,75) and close>strategy.position_avg_price )


//close everything when stoploss hit  
longCloseCondition=close<(strategy.position_avg_price - (strategy.position_avg_price*stopLoss/100)  ) //or crossunder(myRsi,30)
strategy.close("RSI_W_LE", comment="SL Exit", qty=strategy.position_size,when=longCloseCondition )



আরো