Yugen Donchian Trend
- Experts
-
Yogeswaran Suppiah
Independent MetaTrader developer based in Malaysia, publishing chart analysis tools for discretionary traders. On MQL5 since 2015. - Version: 4.5
FOR XAUUSD (GOLD) ON H4. This EA was developed and tested on gold only. It will run on any symbol you attach it to, but everything below was measured on XAUUSD H4 and nothing outside that is supported by testing. It warns you in the Experts log if you attach it elsewhere. A Donchian channel breakout with an EMA trend filter. No grid, no martingale, no averaging, no recovery. One position at a time, a stop loss on every trade from the moment it opens.
HOW IT TRADES The EA enters when price closes beyond a 40-bar Donchian channel and the EMA 50/300 trend filter agrees with the direction. It takes 75% off at 1.5R, moves the remainder to breakeven, and trails it with an ATR stop. Position size comes from ATR risk, not a fixed lot.
BACKTEST: XAUUSD H4, 2020-01 to 2026-08, 10 000 USD, 0.75% risk per trade Net profit 4 183 USD Profit factor 1.79 Maximum equity drawdown 6.89% 238 trades, 59.4% of positions profitable Average holding time about 25 hours Broker: real tick history, 1-minute OHLC modelling. The full Strategy Tester report is in the screenshots.
WHAT YOU SHOULD KNOW BEFORE RUNNING IT It trades about 29 times a year, roughly once every 12 days. More than half of all weeks contain no trade at all. If you expect daily activity you will think it has stopped working; it has not. Results vary a lot year to year. Each figure is that year's profit as a percent of the initial 10 000 USD deposit, not a compounded annual return: 2020 +5.8%, 2021 +3.7%, 2022 -2.4%, 2023 +2.1%, 2024 +9.4%, 2025 +21.2%, 2026 to date +2.1%. One year in this sample lost money, and one year produced roughly half the total profit. A backtest average is not a forecast. It is a trend-following system. It earns when gold trends and gives some of it back when gold ranges. There is no filter that reliably predicts which is coming. There is no live track record. This is free precisely because I am not going to charge for a system whose forward performance I cannot show you.
RECOMMENDED SETUP Symbol XAUUSD, any broker suffix (XAUUSD.m, GOLD, XAUUSD.ecn) Chart timeframe: any, the EA reads H4 internally Risk 0.75% per trade, the tested value About 3 900 USD to run 0.01 lot at that risk. Below this you are running at higher risk than was tested. Leverage 1:100 or better, ECN or raw spread account preferred Two set files are provided: H4 primary, D1 as a lower-frequency variant.
SETTINGS Only ten parameters are exposed. Everything else is fixed at the tested values on purpose, so the strategy cannot be turned into something that was never validated. InpTradingEnabled - master on and off switch InpMagicNumber - change if you run several EAs on one account InpTradeComment - order comment InpVerboseLog - extra logging InpSignalTF - H4 or D1 InpRiskPercent - risk per trade as a percent of equity InpMaxLots - hard lot cap, 0 means broker maximum InpMaxDailyLossPercent - daily loss cut-out InpMaxTotalDDPercent - hard equity drawdown stop InpMaxSpreadPoints - spread ceiling, 0 disables it
RISK Trading is risky and you can lose money. Every trade carries a stop loss, and there is a daily loss cut-out and a hard equity drawdown stop, but none of that guarantees anything. Past backtest results do not predict future returns. Use money you can afford to lose and test on a demo account first.
