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が提供または承認する金融、投資、取引、またはその他の種類の助言もしくは推奨であることを意図したものではなく、またこれらに該当するものでもありません。詳細は利用規約をご覧ください。