Pendulum
Pendulum is a momentum-based Expert Advisor that captures market swings by identifying overbought and oversold conditions using oscillator indicators. It enters trades when momentum signals a reversal from extreme levels, aiming to profit from the natural oscillation of price like a pendulum. The EA employs a systematic approach with defined entry and exit rules based on momentum extremes.
Open the interactive view (equity curve, symbol switch)Key facts
Backtest results (H1, about 1 year)
| Symbol | P&L | Annual | Max DD | Trades | Win rate | Sharpe | Recovery | Losing streak | Per trade | Status |
|---|---|---|---|---|---|---|---|---|---|---|
| EURUSD | -4.38% | -3.82% | 6.06% | 119 | 44.90% | -0.97 | -0.72 | 6 | −$3.42 | Reliable |
| GBPUSD | -1.26% | -1.09% | 5.89% | 113 | 53.60% | -0.19 | -0.21 | 6 | −$0.91 | Reliable |
| USDJPY | -3.30% | -2.87% | 7.83% | 128 | 53.90% | -0.75 | -0.42 | 6 | −$2.58 | Reliable |
| XAUUSD | +15.22% | +12.42% | 52.95% | 109 | 47.20% | 0.54 | 0.29 | 6 | +$16.39 | Reliable |
Profitable on 1 of 4 markets with reliable results.
Converted from MQL5 to Python and run with the same rules for every EA. Positions use MT5 lot sizes (100,000 units per FX lot, 100 oz per gold lot) with 1:100 leverage, one order at a time, and a stop-out below 10% of the starting balance. Sharpe is computed from the equity curve. Results marked as unreliable are shown for completeness only.
Against the other Momentum EAs with a reliable result on the same market: EURUSD: better than 19% of 68 · GBPUSD: better than 50% of 66 · USDJPY: better than 26% of 68 · XAUUSD: better than 61% of 75
Month by month
| Market | Months with a gain | Best month | Worst month |
|---|---|---|---|
| EURUSD | 38% | +1.72% 2026-03 | -1.97% 2026-04 |
| GBPUSD | 46% | +2.35% 2026-04 | -1.86% 2026-09 |
| USDJPY | 46% | +1.58% 2026-04 | -3.38% 2026-01 |
| XAUUSD | 62% | +15.90% 2025-12 | -19.71% 2026-08 |
From the backtest equity curve, sampled about every two days; only reliable results.
Blow-up risk: No blow-up pattern found
None of the usual blow-up patterns were found in the code, and the account was not stopped out in our backtests. That is not a guarantee: any EA can lose money.
High: stopped out in our backtest, or martingale/grid sizing without a stop loss. Elevated: martingale or grid sizing with a stop loss, or several positions at once without a stop loss. What the label means and what we found →
Strategy analysis
The core strategy concept of the Pendulum EA is based on the oscillating nature of market momentum, analogous to pendulum motion where price at extreme levels generates a restoring force. Entry conditions rely on momentum oscillator indicators (such as RSI or Stochastic) reaching overbought or oversold zones followed by reversal signals—going long when an upward reversal occurs from oversold territory and going short when a downward reversal appears from overbought territory. Exit conditions include take-profit targets set at levels where momentum reverts to its mean, along with stop-loss protection against sustained adverse momentum moves. Position sizing may employ fixed lot sizes or dynamic lot calculation based on account risk parameters. Money management is handled through stop-loss to take-profit ratio controls that manage risk exposure per trade, though the strictness of money management depends on parameter configuration.
Strengths
- Momentum reversal strategy logic is clear and aligns with statistical properties of mean reversion in markets
- Includes stop-loss and take-profit mechanisms providing a basic risk control framework
- Strategy concept is intuitive and easy to understand with adjustable parameters suitable for optimization and backtesting
Weaknesses
- Momentum indicators tend to produce false reversal signals in strong trending markets leading to consecutive losses
- Lacks multi-timeframe confirmation mechanism, single indicator judgment may increase false signal risk
- Does not include spread filter or slippage protection, potentially incurring extra costs during volatile conditions
Possible improvements
- Add multi-timeframe trend confirmation to only enter trades when aligned with higher timeframe trend direction, filtering counter-trend signals
- Implement spread filter and trading session control to avoid opening positions during low liquidity or excessively wide spread conditions
Risk assessment
Overall risk: Medium
- Reliance on a single momentum indicator may continuously generate counter-trend signals in trending markets
- No position doubling or grid mechanism but also lacks comprehensive money management strategy, consecutive losses could erode the account
Evaluation scores
Parameters
| Parameter | Default | Description |
|---|---|---|
LotSize | 0.1 | Fixed trading lot size |
StopLoss | 50 | Stop loss in points |
TakeProfit | 100 | Take profit in points |
MomentumPeriod | 14 | Momentum indicator period |
OverboughtLevel | 70 | Overbought threshold |
OversoldLevel | 30 | Oversold threshold |
MagicNumber | 12345 | EA magic number for distinguishing orders |
Timeframe | H1 | Trading timeframe |
Similar Momentum EAs
Backtests are historical simulations and do not guarantee future results. Not financial advice.