
Chiến lược này được gọi là chiến lược hội tụ nhiều yếu tố EMA-RSI-Supertrend, kết hợp các chỉ số trung bình di chuyển ((EMA), chỉ số tương đối mạnh ((RSI), chỉ số siêu xu hướng ((Supertrend) và tín hiệu xác nhận giao dịch, xây dựng một hệ thống giao dịch đa yếu tố. Chiến lược sử dụng EMA 8 chu kỳ và 21 chu kỳ EMA như một tín hiệu cơ bản, hỗ trợ bởi bộ lọc trục trung tâm của RSI và xác nhận xu hướng của Supertrend, cuối cùng xác nhận độ tin cậy của tín hiệu bằng cách mở rộng giao dịch.
Chiến lược này thực hiện tín hiệu giao dịch xu hướng chất lượng cao thông qua sự phối hợp của nhiều yếu tố, đặc biệt phù hợp với giai đoạn thị trường có xu hướng rõ ràng. Cơ chế xác minh bốn lần có hiệu quả trong việc nâng cao độ tin cậy tín hiệu, nhưng cần chú ý đến điều chỉnh thích ứng trong thị trường bất ổn. Trong tương lai, có thể nâng cao sự ổn định hiệu suất hơn nữa thông qua các tham số động và chiến lược thoát cấp. Nói chung, đây là một hệ thống theo dõi xu hướng có cấu trúc nghiêm ngặt, logic rõ ràng, có giá trị ứng dụng thực tại cao hơn.
/*backtest
start: 2024-04-24 00:00:00
end: 2025-04-23 00:00:00
period: 1d
basePeriod: 1d
exchanges: [{"eid":"Futures_Binance","currency":"TRX_USD"}]
*/
//@version=5
//@WunderTrading
strategy("Nirvana Mode v1.0", overlay=true, default_qty_type=strategy.percent_of_equity, default_qty_value=100, calc_on_every_tick=true)
// === INPUTS ===
emaShort = ta.ema(close, 8)
emaLong = ta.ema(close, 21)
rsi = ta.rsi(close, 14)
supertrendFactor = 3.0
supertrendPeriod = 10
[supertrend, direction] = ta.supertrend(supertrendFactor, supertrendPeriod)
volumeAvg = ta.sma(volume, 10)
volumeSpike = volume > volumeAvg * 1.8
// === ENTRY CONDITIONS ===
longCond = ta.crossover(emaShort, emaLong) and rsi > 50 and direction == 1 and volumeSpike
shortCond = ta.crossunder(emaShort, emaLong) and rsi < 50 and direction == -1 and volumeSpike
exitCond = ta.cross(close, emaLong)
// === PLOT & SIGNALS ===
plot(emaShort, color=color.orange)
plot(emaLong, color=color.blue)
plotshape(longCond, title="BUY", location=location.belowbar, color=color.green, style=shape.triangleup, size=size.small)
plotshape(shortCond, title="SELL", location=location.abovebar, color=color.red, style=shape.triangledown, size=size.small)
plotshape(exitCond, title="EXIT", location=location.bottom, color=color.gray, style=shape.xcross, size=size.tiny)
// === STRATEGY ORDERS ===
if (longCond)
strategy.entry("ENTER LONG", strategy.long, comment="ENTER-LONG_BITGET_BTCUSDT_NirvanaMode-v1.0_15M_hmq9xx")
if (shortCond)
strategy.entry("ENTER SHORT", strategy.short, comment="ENTER-SHORT_BITGET_BTCUSDT_NirvanaMode-v1.0_15M_hmq9xx")
if (exitCond)
strategy.close_all(comment="EXIT-ALL_BITGET_BTCUSDT_NirvanaMode-v1.0_15M_hmq9xx")
// === ALERT ===
alertcondition(longCond, title="Long Signal", message="ENTER-LONG_BITGET_BTCUSDT_NirvanaMode-v1.0_15M_hmq9xx")
alertcondition(shortCond, title="Short Signal", message="ENTER-SHORT_BITGET_BTCUSDT_NirvanaMode-v1.0_15M_hmq9xx")
alertcondition(exitCond, title="Exit Signal", message="EXIT-ALL_BITGET_BTCUSDT_NirvanaMode-v1.0_15M_hmq9xx")