
यह रणनीति गतिशीलता संकेतक आरएसआई और रुझान संकेतक ईएमए के संयोजन के साथ एक मिश्रित ट्रेडिंग प्रणाली है। यह 1 मिनट और 5 मिनट के दो समय चक्रों पर चलता है और आरएसआई के ओवरबॉय और ओवरसोल सिग्नल के साथ-साथ ट्रिपल ईएमए के रुझान निर्णय के माध्यम से ट्रेडिंग निर्णय लेता है। रणनीति में ट्रेंड ट्रैकिंग और औसत मूल्य रिटर्न दोनों शामिल हैं, जो विभिन्न बाजार स्थितियों में व्यापार के अवसरों को पकड़ने में सक्षम हैं।
रणनीति 21/50/200 दिन के ट्रिपल ईएमए को ट्रेंडिंग बेंचमार्क के रूप में उपयोग करती है, जबकि सुधारित आरएसआई (चेबशेव पद्धति का उपयोग करके गणना की जाती है) के साथ बाजार के ओवरबॉय ओवरसोल की स्थिति की पहचान करने के लिए। 1 मिनट की अवधि में, जब आरएसआई 94 को तोड़ता है, तो यह कम हो जाता है, 4 घंटे की स्थिति में गिर जाता है, और आरएसआई 50 पर वापस आ जाता है, तो यह रोक देता है। 5 मिनट की अवधि में, जब कीमत 200 दिन के ईएमए को तोड़ती है और रिबाउंड के लिए खुली होती है, तो यह अधिक हो जाती है।
रणनीति कई तकनीकी संकेतकों और कई समय चक्र विश्लेषण के संयोजन के माध्यम से व्यापार की स्थिरता और विश्वसनीयता में सुधार करती है। हालांकि कुछ जोखिम मौजूद हैं, उचित स्थिति प्रबंधन और स्टॉपलॉस तंत्र के माध्यम से जोखिम को प्रभावी रूप से नियंत्रित किया जा सकता है। रणनीति के अनुकूलन के लिए जगह बड़ी है, और अधिक तकनीकी संकेतकों और अनुकूलन मापदंडों को पेश करके रणनीति के प्रदर्शन को और बढ़ाया जा सकता है।
/*backtest
start: 2023-11-12 00:00:00
end: 2024-07-10 00:00:00
period: 1d
basePeriod: 1d
exchanges: [{"eid":"Futures_Binance","currency":"BTC_USDT"}]
*/
//@version=5
strategy("Combined RSI Primed and 3 EMA Strategy", overlay=true)
// Input for EMA lengths
emaLength1 = input(21, title="EMA Length 1")
emaLength2 = input(50, title="EMA Length 2")
emaLength3 = input(200, title="EMA Length 3")
// Input for RSI settings
rsiLength = input(14, title="RSI Length")
rsiOverbought = input(94, title="RSI Overbought Level")
rsiNeutral = input(50, title="RSI Neutral Level")
rsiOversold = input(4, title="RSI Oversold Level")
// Calculate EMAs
ema1 = ta.ema(close, emaLength1)
ema2 = ta.ema(close, emaLength2)
ema3 = ta.ema(close, emaLength3)
// Calculate RSI using Chebyshev method from RSI Primed
rsi(source) =>
up = math.max(ta.change(source), 0)
down = -math.min(ta.change(source), 0)
rs = up / down
rsiValue = down == 0 ? 100 : 100 - (100 / (1 + rs))
rsiValue
rsiValue = rsi(close)
// Plot EMAs
plot(ema1, color=color.red, title="EMA 21")
plot(ema2, color=color.white, title="EMA 50")
plot(ema3, color=color.blue, title="EMA 200")
// Plot RSI for visual reference
hline(rsiOverbought, "Overbought", color=color.red)
hline(rsiNeutral, "Neutral", color=color.gray)
hline(rsiOversold, "Oversold", color=color.green)
plot(rsiValue, color=color.blue, title="RSI")
// Trading logic with position management
var bool inPositionShort = false
var bool inPositionLong = false
// Trading logic for 1-minute timeframe
if (rsiValue > rsiOverbought and not inPositionShort)
strategy.entry("Sell", strategy.short)
inPositionShort := true
if (rsiValue < rsiOversold and inPositionShort)
strategy.close("Sell")
inPositionShort := false
if (ta.crossover(rsiValue, rsiNeutral) and inPositionShort)
strategy.exit("Break Even", "Sell", stop=close)
// Trading logic for 5-minute timeframe
var float lastBearishClose = na
if (close < ema3 and close[1] >= ema3) // Check if the current close is below EMA200
lastBearishClose := close
if (not na(lastBearishClose) and close > lastBearishClose and not inPositionLong)
strategy.entry("Buy", strategy.long)
inPositionLong := true
if (rsiValue > rsiOverbought and inPositionLong)
strategy.close("Buy")
inPositionLong := false
if (ta.crossunder(rsiValue, rsiNeutral) and inPositionLong)
strategy.exit("Break Even", "Buy", stop=close)
lastBearishClose := na // Reset after trade execution