रिवर्सल इंडिकेटर रणनीति

लेखक:चाओझांग, दिनांकः 2023-12-13 14:45:51
टैगः

img

अवलोकन

यह कई तकनीकी संकेतकों के आधार पर एक पुनर्विक्रय ट्रेडिंग रणनीति है। यह संभावित लंबी और छोटी ट्रेडिंग अवसरों की पहचान करने के लिए सीसीआई, मोमेंटम संकेतक, आरएसआई और अन्य संकेतकों को जोड़ती है। यह रणनीति ट्रेडिंग संकेत उत्पन्न करती है जब संकेतक ओवरबॉट / ओवरसोल्ड संकेत दिखाते हैं और कीमतें वापस खींचती हैं।

रणनीति तर्क

रणनीति के ट्रेडिंग सिग्नल एक कस्टम संकेतक से आते हैं जिसे एड्री एक्सट्रीम पॉइंट्स बाय एंड सेल कहा जाता है। यह सीसीआई, मोमेंटम संकेतक और आरएसआई क्रॉसओवर को ध्यान में रखता है। विशिष्ट तर्क हैंः

लंबे सिग्नल की स्थितिः

  1. Edri Extreme Points Buy & Sell सूचक एक खरीद संकेत को ट्रिगर करता है, अर्थात CCI 0 से ऊपर या Momentum 0 से ऊपर जाता है और RSI ओवरसोल्ड स्तर से नीचे होता है।
  2. कीमत 100 अवधि के ईएमए तक या उससे नीचे खींचती है।

संक्षिप्त संकेत की स्थितिः

  1. Edri Extreme Points Buy & Sell सूचक एक बिक्री संकेत को ट्रिगर करता है, अर्थात CCI 0 से नीचे या Momentum 0 से नीचे जाता है और RSI ओवरबॉट स्तर से ऊपर होता है।
  2. कीमत 100 अवधि के ईएमए तक या उससे ऊपर वापस खींचती है।

रणनीति को नियमित तेजी/बियर विचलन खोजने के लिए भी कॉन्फ़िगर किया जा सकता है, केवल तभी ट्रेडिंग सिग्नल उत्पन्न होता है जब आरएसआई मूल्य से काफी भिन्न होता है।

जब ट्रेडिंग सिग्नल ट्रिगर किए जाते हैं, तो रणनीति स्टॉप लॉस को प्रवेश मूल्य ± 2ATR पर सेट करती है, प्रवेश मूल्य ± 4ATR पर लाभ लेती है। यह बाजार की अस्थिरता के आधार पर उचित स्टॉप लॉस और लाभ लेने की सीमा की अनुमति देता है।

लाभ विश्लेषण

  1. एकाधिक संकेतकों को मिलाकर एक ही संकेतकों से झूठे संकेतों से बचा जा सकता है।
  2. रिवर्सल ट्रेडिंग शैली सीमा-बंद बाजारों में मध्यम अवधि के अवसरों को पकड़ती है।
  3. एटीआर-आधारित स्टॉप लॉस और टेक प्रॉफिट बाजार की अस्थिरता के आधार पर पदों को समायोजित कर सकते हैं।
  4. विचलन का पता लगाने से अत्यधिक ओवरबॉट/ओवरसोल्ड स्तरों के बिना पदों को खोलने से बचा जाता है।

जोखिम विश्लेषण

  1. अनुचित संकेतक मापदंडों के कारण अवसरों को खोया जा सकता है या बहुत सारे गलत संकेत हो सकते हैं।
  2. रिवर्स ट्रेडिंग से ट्रेंडिंग बाजारों में लगातार स्टॉप लॉस हो सकता है।
  3. एटीआर का प्रभाव धीमा रहता है और तेजी से चल रहे बाजारों में स्टॉप लॉस/टेक प्रॉफिट को समय पर अपडेट नहीं कर सकता है।

समाधान:

  1. सर्वोत्तम संयोजन खोजने के लिए सूचक मापदंडों का बैकटेस्ट और अनुकूलन करें।
  2. जब प्रवृत्ति मजबूत हो तब रणनीति को निलंबित करने पर विचार करें।
  3. अन्य स्टॉप लॉस विधियों के साथ संयोजन करें जैसे कि स्टॉप लॉस को स्थानांतरित करना या विपरीत स्टॉप लॉस करना।

अनुकूलन दिशाएँ

  1. सीसीआई, गति लंबाई, आरएसआई पैरामीटर, एटीआर गुणक आदि के विभिन्न पैरामीटर संयोजनों का परीक्षण करें।
  2. अन्य फ़िल्टरिंग शर्तें जैसे मूल्य पैटर्न, मात्रा परिवर्तन आदि जोड़ें।
  3. एटीआर-आधारित स्थिति अनुपात जैसे स्थिति आकार नियमों को समायोजित करें।
  4. विभिन्न उत्पादों और समय सीमाओं के लिए पैरामीटर टेम्पलेट सेट करें।
  5. ट्रेंडिंग बाजारों में रिवर्स ट्रेडिंग को निलंबित करने के लिए ट्रेंड ट्रैकिंग जोड़ने पर विचार करें।

सारांश

यह रणनीति मुख्य रूप से रेंज-बाउंड बाजारों के लिए काम करती है, अपेक्षाकृत स्थिर लाभ के लिए मध्यम अवधि के उलटफेर को पकड़ती है। यह अल्पकालिक मूल्य खिंचाव की पहचान करने में मदद करती है और कई संकेतकों के आधार पर ट्रेडिंग सिग्नल उत्पन्न करती है। उचित अनुकूलन और जोखिम प्रबंधन के साथ, इसके लाभों का प्रभावी ढंग से उपयोग किया जा सकता है। फिर भी रिवर्सल ट्रेडिंग की अंतर्निहित कमजोरियों, मजबूत रुझानों में निरंतर नुकसान की संभावना से अवगत रहें। कुल मिलाकर रणनीति कुछ मात्रा और जोखिम प्रबंधन अनुभव वाले निवेशकों के लिए उपयुक्त है।


/*backtest
start: 2023-11-12 00:00:00
end: 2023-12-02 00:00:00
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/
// © MagicStrategies

//@version=5
strategy("Reversal Indicator Strategy", overlay = true)

// Input settings
ccimomCross = input.string('CCI', 'Entry Signal Source', options=['CCI', 'Momentum'], tooltip='CCI or Momentum will be the final source of the Entry signal if selected.')
ccimomLength = input.int(10, minval=1, title='CCI/Momentum Length')
useDivergence = input.bool(true, title='Find Regular Bullish/Bearish Divergence', tooltip='If checked, it will only consider an overbought or oversold condition that has a regular bullish or bearish divergence formed inside that level.')
rsiOverbought = input.int(65, minval=1, title='RSI Overbought Level', tooltip='Adjusting the level to extremely high may filter out some signals especially when the option to find divergence is checked.')
rsiOversold = input.int(35, minval=1, title='RSI Oversold Level', tooltip='Adjusting this level extremely low may filter out some signals especially when the option to find divergence is checked.')
rsiLength = input.int(14, minval=1, title='RSI Length')
plotMeanReversion = input.bool(false, 'Plot Mean Reversion Bands on the chart', tooltip='This function doesn\'t affect the entry of signal but it suggests buying when the price is at the lower band, and then sell it on the next bounce at the higher bands.')
emaPeriod = input(200, title='Lookback Period (EMA)')
bandMultiplier = input.float(1.8, title='Outer Bands Multiplier', tooltip='Multiplier for both upper and lower bands')


// CCI and Momentum calculation
momLength = ccimomCross == 'Momentum' ? ccimomLength : 10
mom = close - close[momLength]
cci = ta.cci(close, ccimomLength)
ccimomCrossUp = ccimomCross == 'Momentum' ? ta.cross(mom, 0) : ta.cross(cci, 0)
ccimomCrossDown = ccimomCross == 'Momentum' ? ta.cross(0, mom) : ta.cross(0, cci)

// RSI calculation
src = close
up = ta.rma(math.max(ta.change(src), 0), rsiLength)
down = ta.rma(-math.min(ta.change(src), 0), rsiLength)
rsi = down == 0 ? 100 : up == 0 ? 0 : 100 - 100 / (1 + up / down)
oversoldAgo = rsi[0] <= rsiOversold or rsi[1] <= rsiOversold or rsi[2] <= rsiOversold or rsi[3] <= rsiOversold
overboughtAgo = rsi[0] >= rsiOverbought or rsi[1] >= rsiOverbought or rsi[2] >= rsiOverbought or rsi[3] >= rsiOverbought

// Regular Divergence Conditions
bullishDivergenceCondition = rsi[0] > rsi[1] and rsi[1] < rsi[2]
bearishDivergenceCondition = rsi[0] < rsi[1] and rsi[1] > rsi[2]

// Entry Conditions
longEntryCondition = ccimomCrossUp and oversoldAgo and (not useDivergence or bullishDivergenceCondition)
shortEntryCondition = ccimomCrossDown and overboughtAgo and (not useDivergence or bearishDivergenceCondition)


// Mean Reversion Indicator
meanReversion = plotMeanReversion ? ta.ema(close, emaPeriod) : na
stdDev = plotMeanReversion ? ta.stdev(close, emaPeriod) : na
upperBand = plotMeanReversion ? meanReversion + stdDev * bandMultiplier : na
lowerBand = plotMeanReversion ? meanReversion - stdDev * bandMultiplier : na


// Plotting
plotshape(longEntryCondition, title='BUY', style=shape.triangleup, text='B', location=location.belowbar, color=color.new(color.lime, 0), textcolor=color.new(color.white, 0), size=size.tiny)
plotshape(shortEntryCondition, title='SELL', style=shape.triangledown, text='S', location=location.abovebar, color=color.new(color.red, 0), textcolor=color.new(color.white, 0), size=size.tiny)

plot(upperBand, title='Upper Band', color=color.new(color.fuchsia, 0), linewidth=1)
plot(meanReversion, title='Mean', color=color.new(color.gray, 0), linewidth=1)
plot(lowerBand, title='Lower Band', color=color.new(color.blue, 0), linewidth=1)

// Entry signal alerts
alertcondition(longEntryCondition, title='BUY Signal', message='Buy Entry Signal')
alertcondition(shortEntryCondition, title='SELL Signal', message='Sell Entry Signal')
alertcondition(longEntryCondition or shortEntryCondition, title='BUY or SELL Signal', message='Entry Signal')

ema100 = ta.ema(close, 100)
plot(ema100, color=color.red)

// Define trading signals based on the original indicator's entry conditions
// Buy if long condition is met and price has pulled back to or below the 100 EMA
longCondition  = longEntryCondition and close <= ema100
// Sell if short condition is met and price has pulled back to or above the 100 EMA
shortCondition = shortEntryCondition and close >= ema100

// Strategy Entries
if longCondition
    strategy.entry("Buy", strategy.long)
if shortCondition
    strategy.entry("Sell", strategy.short)

अधिक