चांद का प्रहार दोहरी त्रिभुज ब्रेकआउट रणनीति

लेखक:चाओझांग, दिनांक: 2023-11-21 13:49:10
टैगः

img

अवलोकन

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

रणनीति तर्क

  1. मूल्य की अल्पकालिक, मध्यमकालिक और दीर्घकालिक प्रवृत्ति दिशाओं का न्याय करने के लिए विभिन्न मापदंडों के साथ 3 सुपर ट्रेंड बनाएं।

  2. यह निर्धारित करने के लिए दोहरी त्रिकोण चैनल का उपयोग करें कि क्या मूल्य प्रवेश और निकास संकेतों के रूप में ऊपरी या निचले चैनल को तोड़ता है।

  3. 233-अवधि ईएमए को मिलाकर समग्र प्रवृत्ति दिशा निर्धारित करें। जब कीमत एक अपट्रेंड बाजार में ऊपरी चैनल को तोड़ती है और ईएमए द्वारा आंका गया डाउनट्रेंड बाजार में निचले चैनल को तोड़ते समय शॉर्ट जाती है।

  4. 3 सुपर ट्रेंड्स के क्रॉसओवर सिग्नल का उपयोग लाभ लेने और स्टॉप लॉस निर्धारित करने के लिए करें। जब 2 या अधिक संकेतक रंग बदलते हैं तो पदों को बंद करें।

लाभ

  1. कई समय सीमाओं के साथ संयुक्त दोहरी त्रिकोण चैनल ट्रेंड ब्रेकआउट को सटीक रूप से पकड़ सकता है।

  2. मल्टी-लेयर स्क्रीनिंग से अप्रभावी ट्रेडों से बचा जाता है और जीत की दर में सुधार होता है।

  3. गतिशील अनुवर्ती स्टॉप लॉस ड्रॉडाउन जोखिम को कम करता है।

  4. सरल पैरामीटर सेटअप इसका उपयोग करना आसान बनाता है।

जोखिम और अनुकूलन

  1. व्यापारिक आवृत्ति को कम करने के लिए एटीआर अवधि को समायोजित करें।

  2. ईएमए अवधि बहुत कम है, प्रवृत्ति को पकड़ने में विफल रहता है, प्रवृत्ति परिवर्तन में बहुत लंबा समय लगता है। बैकटेस्ट के माध्यम से ईएमए पैरामीटर का अनुकूलन करें।

  3. स्थैतिक स्टॉप लॉस गतिशील बाजार अस्थिरता को अनुकूलित करने में विफल रहता है। ट्रेल स्टॉप स्तरों के लिए एटीआर का उपयोग करने पर विचार करें।

निष्कर्ष

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


/*backtest
start: 2023-11-13 00:00:00
end: 2023-11-17 04:00:00
period: 10m
basePeriod: 1m
exchanges: [{"eid":"Futures_Binance","currency":"BTC_USDT"}]
*/

// @version=5
// author=theasgard and moonshot-indicator (ms)
// year 2021
//
// This is a well knowen strategy by using 3 different Supertrends and a trend-defining EMA,
// feel free to play around with the settings, a backtest on 8h ETHUSDT pair brought some good results using 
// the 233EMA and investing 75% of a 10k start capital
//
// the idea is to have at least 2 supertrnds going green above the trend-EMA to go long and exit by turning 
// 2 supertrends red (idea: 1 supertrend in red could initialize a take profit)
// shorts work vice versa
// The EMA shows in green for uptrends and in red for downtrends, if it is blue no Signal will be taken because 
// the 3 supertrends are not all above or below the trendline(EMA)

strategy("ms hypertrender", overlay=true)

// set up 3 supertrendlines and colour the direction up/down
atrPeriod1 = input(10, "ATR Length 1")
factor1 = input.float(1.0, "ATR Factor 1", step = 0.01)
[supertrend1, direction1] = ta.supertrend(factor1, atrPeriod1)
upTrend1 = plot(direction1 < 0 ? supertrend1 : na, "Up Trend 1", color = color.green, style=plot.style_linebr)
downTrend1 = plot(direction1 < 0? na : supertrend1, "Down Trend 1", color = color.red, style=plot.style_linebr)

atrPeriod2 = input(11, "ATR Length 2")
factor2 = input.float(2.0, "ATR Factor 2", step = 0.01)
[supertrend2, direction2] = ta.supertrend(factor2, atrPeriod2)
upTrend2 = plot(direction2 < 0 ? supertrend2 : na, "Up Trend 2", color = color.green, style=plot.style_linebr)
downTrend2 = plot(direction2 < 0? na : supertrend2, "Down Trend 2", color = color.red, style=plot.style_linebr)

atrPeriod3 = input(12, "ATR Length 3")
factor3 = input.float(3.0, "ATR Factor 3", step = 0.01)
[supertrend3, direction3] = ta.supertrend(factor3, atrPeriod3)
upTrend3 = plot(direction3 < 0 ? supertrend3 : na, "Up Trend 1", color = color.green, style=plot.style_linebr)
downTrend3 = plot(direction3 < 0? na : supertrend3, "Down Trend 1", color = color.red, style=plot.style_linebr)

//set up the trend dividing EMA and color uptrend nutreal downtrend
len = input.int(233, minval=1, title="Trend-EMA Length")
src = input(close, title="Source")
offset = input.int(title="Offset", defval=0, minval=-500, maxval=500)

//general Bull or Bear Trend? Visualized by ema
ematrend = ta.ema(src, len)
generaluptrend = supertrend1 > ematrend and supertrend2 > ematrend and supertrend3 > ematrend
generaldowntrend = supertrend1 < ematrend and supertrend2 < ematrend and supertrend3 < ematrend
emacolor = if generaluptrend
    color.green
else if generaldowntrend
    color.red
else
    color.blue
plot(ematrend, title="EMA", color=emacolor, offset=offset)

// Bullish? min 2 supertrends green
bullish = (direction1 < 0 and direction2 < 0) or (direction1 < 0 and direction3 < 0) or (direction2 < 0 and direction3 < 0) and generaluptrend
extremebullish = direction1 < 0 and direction2 < 0 and direction3 < 0 and generaluptrend //all 3 green

// Bearish? min 2 supertrends red
bearish = (direction1 > 0 and direction2 > 0) or (direction1 > 0 and direction3 > 0) or (direction2 > 0 and direction3 > 0) and generaldowntrend
extremebearish = direction1 > 0 and direction2 > 0 and direction3 > 0 and generaldowntrend //all 3 red

// Open Long
//plotchar(((bullish and not bullish[1]) or (extremebullish and not extremebullish[1])) and (emacolor==color.green)? close : na, title = 'Start Long', char='▲', color = #80eb34, location = location.belowbar, size = size.small)

// TP 10% Long
TP10long = ((generaluptrend and bullish[1]) or (generaluptrend and extremebullish[1])) and (direction1 > 0 or direction2 > 0 or direction3 > 0)
//plotchar(TP10long and not TP10long[1]? close : na, title = 'TP on Long', char='┼', color = #ffd000, location = location.abovebar, size = size.tiny)

// Exit Long
//plotchar(extremebearish and not extremebearish[1] or bearish and not bearish[1]? close : na, title = 'Close all Longs', char='Ꭓ', color = #ff0037, location = location.abovebar, size = size.tiny)

// Open Short
//plotchar(((bearish and not bearish[1]) or (extremebearish and not extremebearish[1])) and (emacolor==color.red)? close : na, title = 'Start Short', char='▼', color = #0547e3, location = location.abovebar, size = size.small)

// TP 10% Short
TP10short = ((generaldowntrend and bearish[1]) or (generaldowntrend and extremebearish[1])) and (direction1 < 0 or direction2 < 0 or direction3 < 0)
//plotchar(TP10short and not TP10short[1]? close : na, title = 'TP on Short', char='┼', color = #ffd000, location = location.belowbar, size = size.tiny)

// Exit Short
//plotchar(extremebullish and not extremebullish[1] or bullish and not bullish[1]? close : na, title = 'Close all Shorts', char='Ꭓ', color = #ff0037, location = location.belowbar, size = size.tiny)

// Set stop loss level with input options (optional)
longLossPerc = input.float(title="Long Stop Loss (%)",
     minval=0.0, step=0.1, defval=1) * 0.01

shortLossPerc = input.float(title="Short Stop Loss (%)",
     minval=0.0, step=0.1, defval=1) * 0.01
     
// Determine stop loss price
longStopPrice  = strategy.position_avg_price * (1 - longLossPerc)
shortStopPrice = strategy.position_avg_price * (1 + shortLossPerc)

openlong = (((bullish and not bullish[1]) or (extremebullish and not extremebullish[1])) and (emacolor==color.green))
openshort = (((bearish and not bearish[1]) or (extremebearish and not extremebearish[1])) and (emacolor==color.red))
exitlong = (extremebearish and not extremebearish[1] or bearish and not bearish[1]) or TP10long
exitshort = (extremebullish and not extremebullish[1] or bullish and not bullish[1]) or TP10short
strategy.entry("buy", strategy.long, when=openlong)
strategy.entry("sell", strategy.short, when=openshort)

strategy.close("buy", when=exitlong)
strategy.close("sell", when=exitshort)

// Submit exit orders based on calculated stop loss price
if (strategy.position_size > 0)
    strategy.exit(id="Long Stop", stop=longStopPrice)

if (strategy.position_size < 0)
    strategy.exit(id="Short Stop", stop=shortStopPrice)

अधिक