Guarda come scaricare robot di trading gratuitamente
Ci trovi su Facebook!
Unisciti alla nostra fan page
Script interessante?
Pubblica il link!
lasciare che altri lo valutino
Ti è piaciuto lo script? Provalo nel Terminale MetaTrader 5
Sistemi Esperti

XANDER Gold Recovery - sistema esperto per MetaTrader 5

Cristhian Alexander Gaibor Cuasquer
Cristhian Alexander Gaibor Cuasquer
  • Founder & Systems Engineer al  Xander Pro
  • Ecuador
  • 7596
4.8 (38)
Trader e membro di MQL5 dal 2017.
Visualizzazioni:
5357
Valutazioni:
(4)
Pubblicato:
Aggiornato:
Freelance MQL5 Hai bisogno di un robot o indicatore basato su questo codice? Ordinalo su Freelance Vai a Freelance

A Keltner style reversal for Gold (XAUUSD): a 50 period EMA with a channel built from the average candle range of the same period. When a candle closes outside the channel and the next one closes back inside, and the 10 EMA agrees with the 200 EMA on direction, the EA opens one trade on the new bar. Buys only above the slow EMA, sells only below it, inside a session window and under a spread cap.

The optional recovery basket adds same direction positions every fixed distance against the first entry, multiplying the lot by a factor you set, up to a hard maximum of orders. The whole basket closes together at a take profit in account currency or at a hard stop in account currency, swap and commission included. With recovery off it is a single trade system with stop loss, take profit and a trailing stop that activates after a trigger distance.

Every order passes a margin check before it is sent and lots are normalised to the broker step. This is still an averaging basket when recovery is on: the hard stop is the only thing that caps the loss, so keep it enabled and sized to your account, and test distance and multiplier in the strategy tester before any live use.

Update v1.2 (October 2026): header and documentation rewritten, link to my MQL5 channel for updates, channel range calculation guarded when the history is shorter than the period, version string fixed in the start message. Logic unchanged.

Settings

  • Base lot size: lot of the first trade, default 0.01.
  • Enable Progressive Recovery: turns the basket on. Off, the EA trades one position at a time.
  • Distance between orders (pips): adverse move before the next recovery order. On gold one pip is 0.01, so 300 pips is a 3.00 USD move on 2 and 3 decimal brokers.
  • Lot multiplier per step: each recovery order multiplies the previous lot, default 1.4. 1.0 keeps a flat lot.
  • Max orders in basket: hard cap of positions in the basket, default 5, accepted range 1 to 20.
  • Basket TP in account currency and Basket Hard Stop in currency: close the whole basket at these floating results. 0 disables each one. The hard stop is your real risk limit.
  • Stop Loss in pips and Take Profit in pips: applied to the first trade only, 0 disables.
  • Trailing trigger, stop and step (pips): trailing stop for single positions, it stays off while the basket has more than one order. Trigger 0 disables.
  • Session filter with start and end hour and minute in server time, default 02:30 to 21:00.
  • Keltner Channel length, Fast EMA period and Slow EMA period: 50, 10 and 200 by default.
  • Max slippage (pips) and Max spread in points: execution filters, spread 0 means unlimited.
  • Magic number and Trade comment.

How to use it

Attach it to one XAUUSD chart. The signal is calculated on the chart timeframe, M15 and H1 are the ones to start testing with. It works on 2 and 3 decimal gold quotes because distances are converted internally. Run it in the strategy tester first with recovery on and off and compare the drawdown of each mode, then move to a demo account before anything else.

Make it yours

The entry is a clean function, GetSignal, so you can replace the channel with Bollinger Bands or an ATR based Keltner, add a Smart Money Concepts zone filter or your own support and resistance levels, and keep the basket engine as it is. Run your own backtests on XAUUSD, XAGUSD, EURUSD or GBPUSD and on M5, M15 and H1. If you prefer to manage the basket from outside, my Basket Pair Closer works next to this EA using the same magic number.

About this code

Open source. Use it as it is, adapt it, build your own version on top of it. New versions and new tools are announced first on my MQL5 channel: https://www.mql5.com/en/channels/xander. Questions, suggestions and your own backtests are welcome in the Xander Lab group: https://www.mql5.com/en/messages/02eec85e4364dd01. More tools on my profile: https://www.mql5.com/en/users/09151993a

Related: Basket Pair Closer, XANDER Grid XAUUSD, Quantum XAUUSD Silver Trader.

Changelog

v1.2 (2026-10-25): documentation and header update, MQL5 channel link, channel range guarded when history is short, version string fixed.
v1.1 (2026-04-23): margin check before every order.
v1.0 (2026-04-23): initial release.

Self-Aware Trend System Self-Aware Trend System

Self-Aware Trend System (SATS) is an advanced MQL5 indicator that combines an adaptive SuperTrend engine with a Trend Quality Index (TQI) dashboard, offering dynamic signal detection, risk management levels, and self-learning calibration for smarter, more reliable trade entries.

Daily Risk Monitor Lite Daily Risk Monitor Lite

Daily Risk Monitor Lite is a lightweight MetaTrader 5 indicator that displays daily realized P/L, floating P/L, daily total, current drawdown, and color-based risk status directly on the chart. It is a read-only monitoring tool and does not close trades or block trading.

Calculate Lot Percent Calculate Lot Percent

Function for lot calculation from deposit percentage

Frontend EA : UI cleanup + quick-trading layer for MT5 Frontend EA : UI cleanup + quick-trading layer for MT5

A chart-cleanup + quick-trading layer for MT5