OPEN-SOURCE SCRIPT
XAUUSD M5 Hybrid EMA 9/15 (Partial TP + Runner)

This strategy is designed specifically for Gold (XAUUSD) on the 5-minute timeframe, combining trend-following EMAs with rejection-based entries and a dual take-profit system to balance consistency and high-reward opportunities.
⚙️ Strategy Logic
The system uses a 9 EMA and 15 EMA crossover to define short-term trend direction, combined with 15-minute higher timeframe confirmation to filter out low-probability trades.
Buy Conditions:
9 EMA above 15 EMA (M5)
9 EMA above 15 EMA (M15 confirmation)
Strong bullish rejection candle (long lower wick + bullish close)
Sell Conditions:
15 EMA above 9 EMA (M5)
15 EMA above 9 EMA (M15 confirmation)
Strong bearish rejection candle (long upper wick + bearish close)
💰 Trade Management (Key Edge)
Each trade is split into two parts:
TP1 (Partial Close – 50%)
Fixed at ~10 pips (1.0 gold point)
Locks in consistent profits
TP2 (Runner – 50%)
Targets ~50 pips (5.0 gold points)
Includes trailing stop to capture extended moves
Stop Loss
Based on EMA structure with buffer
Dynamic and adaptive to market conditions
🎯 Strategy Objective
This hybrid model is designed to:
Generate frequent small wins
Capture larger trend moves when they occur
Reduce drawdown through partial profit-taking
📊 Best Use Case
Instrument: XAUUSD (Gold)
Timeframe: 5 Minutes
Sessions: London & New York
Market Type: Trending / Volatile conditions
⚠️ Important Notes
This is not a guaranteed high win-rate system
Performance depends heavily on:
Market volatility
Session timing
Spread and execution quality
Backtesting and forward testing are strongly recommended before live use.
🚀 Summary
This strategy combines:
Trend alignment
Price action confirmation
Smart trade management
To create a balanced system between consistency and high-reward trades, making it suitable for disciplined intraday traders.
⚙️ Strategy Logic
The system uses a 9 EMA and 15 EMA crossover to define short-term trend direction, combined with 15-minute higher timeframe confirmation to filter out low-probability trades.
Buy Conditions:
9 EMA above 15 EMA (M5)
9 EMA above 15 EMA (M15 confirmation)
Strong bullish rejection candle (long lower wick + bullish close)
Sell Conditions:
15 EMA above 9 EMA (M5)
15 EMA above 9 EMA (M15 confirmation)
Strong bearish rejection candle (long upper wick + bearish close)
💰 Trade Management (Key Edge)
Each trade is split into two parts:
TP1 (Partial Close – 50%)
Fixed at ~10 pips (1.0 gold point)
Locks in consistent profits
TP2 (Runner – 50%)
Targets ~50 pips (5.0 gold points)
Includes trailing stop to capture extended moves
Stop Loss
Based on EMA structure with buffer
Dynamic and adaptive to market conditions
🎯 Strategy Objective
This hybrid model is designed to:
Generate frequent small wins
Capture larger trend moves when they occur
Reduce drawdown through partial profit-taking
📊 Best Use Case
Instrument: XAUUSD (Gold)
Timeframe: 5 Minutes
Sessions: London & New York
Market Type: Trending / Volatile conditions
⚠️ Important Notes
This is not a guaranteed high win-rate system
Performance depends heavily on:
Market volatility
Session timing
Spread and execution quality
Backtesting and forward testing are strongly recommended before live use.
🚀 Summary
This strategy combines:
Trend alignment
Price action confirmation
Smart trade management
To create a balanced system between consistency and high-reward trades, making it suitable for disciplined intraday traders.
開源腳本
秉持TradingView一貫精神,這個腳本的創作者將其設為開源,以便交易者檢視並驗證其功能。向作者致敬!您可以免費使用此腳本,但請注意,重新發佈代碼需遵守我們的社群規範。
免責聲明
這些資訊和出版物並非旨在提供,也不構成TradingView提供或認可的任何形式的財務、投資、交易或其他類型的建議或推薦。請閱讀使用條款以了解更多資訊。
開源腳本
秉持TradingView一貫精神,這個腳本的創作者將其設為開源,以便交易者檢視並驗證其功能。向作者致敬!您可以免費使用此腳本,但請注意,重新發佈代碼需遵守我們的社群規範。
免責聲明
這些資訊和出版物並非旨在提供,也不構成TradingView提供或認可的任何形式的財務、投資、交易或其他類型的建議或推薦。請閱讀使用條款以了解更多資訊。