# Gold Pullback Martingale

Automated trading robot for XAUUSD using a martingale strategy after a pullback.

Canonical: https://prismaticalgos.com/compendium/algo/12429-gold-pullback-martingale
Record ID: 12429
Catalog rank: 441 (reading order, not performance)
Snapshot: 2026-10-31 15:46 UTC
Family: Grid, Martingale & Averaging (C)
Source: https://www.mql5.com/en/market/product/204976
Evidence label (unverified): backtest_shown

## Scope and limitations

These are machine-extracted research records, not verified trading systems. Catalog rank measures specification detail and claimed evidence, not profitability. The catalog extraction pipeline did not independently backtest these records. Its separate selected testing ledger does not validate the wider corpus. Rules, labels and parameters can be incomplete or wrong; consult the original source and its reuse terms.

No endorsement, ownership claim or source-code reuse permission is implied.

## Extraction warnings

Claim warnings: RECOVERY SIZING: position size increases after losses (martingale/grid/averaging). Equity curves look smooth until the run that does not recover - judge it on worst-case exposure, not win rate.

## Recorded profile

- symbols: XAUUSD
- timeframes: H1
- sessions: 02:00–22:00 server time, No new baskets on Friday
- market_regime: trending

## Indicators

- EMA: {"period": 20}; applied to: close
- EMA: {"period": 100}; applied to: close

## Recorded long-entry rules

- Trend: the slow EMA (100) must have risen by at least 0.30 × ATR over the last 10 bars, and the close must be on the trend side of the slow EMA.
- Pullback: the bar touched the fast EMA (20) and closed back beyond it in the trend direction. The candle must also be bullish.

## Recorded short-entry rules

- Trend: the slow EMA (100) must have fallen by at least 0.30 × ATR over the last 10 bars, and the close must be on the trend side of the slow EMA.
- Pullback: the bar touched the fast EMA (20) and closed back beyond it in the trend direction. The candle must also be bearish.

## Recorded exit rules

- Basket take-profit: the basket closes when price is BasketTpAtr × ATR beyond the volume-weighted average price and the basket is in profit.

## Recorded filters

- Spread (as a fraction of ATR and/or in points)
- Trading hours (server time): 02:00–22:00, no new baskets on Friday
- Minimum ATR
- Direction: buy, sell, or both
- Only one basket per symbol and magic number is open at a time

## Risk controls

- Stop loss: Basket SL % of balance at basket start: 10%
- Take profit: Basket TP × ATR: 0.60
- Position sizing: Starting lot: a fixed lot, or a lot per 1,000 of balance. Additional levels: a level is added when price moves against the worst entry by StepAtr × ATR × StepGrowth^(n-1). Lot size: each level's lot = starting lot × multiplier^n (default 1.50, allowed 1.0–3.0).
