Exp_Modified_Optimum_Elliptic_Filter
This EA trades based on the Modified Optimum Elliptic Filter indicator, opening buy positions when the filter values are rising and sell positions when they are falling. It uses a new-bar check to generate signals and applies configurable stop-loss, take-profit, and money management settings. The strategy is a trend-following system that enters in the direction of the filter's slope.
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 | 0.00% | 0.00% | 0.00% | 0 | — | — | — | — | — | Not convertible yet |
| GBPUSD | 0.00% | 0.00% | 0.00% | 0 | — | — | — | — | — | Not convertible yet |
| USDJPY | 0.00% | 0.00% | 0.00% | 0 | — | — | — | — | — | Not convertible yet |
| XAUUSD | 0.00% | 0.00% | 0.00% | 0 | — | — | — | — | — | Not convertible yet |
Why this EA never traded: no entry rule survived the conversion.
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.
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
This EA uses the Modified Optimum Elliptic Filter as its core trend-determination indicator, comparing three consecutive filter values to identify trend direction. Entry conditions are: a buy position opens when Value[1]<Value[2] (filter rising) and Value[0]>Value[1] (continuing to rise); a sell position opens when Value[1]>Value[2] (filter falling) and Value[0]<Value[1] (continuing to fall). Exit conditions rely on fixed stop-loss and take-profit settings, and opposing signals also trigger position closes (e.g., a sell signal closes any open buy position). Position sizing is controlled via the MM parameter, supporting both LOT and MARGIN modes through the MarginMode enumeration. Money management uses standardized functions from the TradeAlgorithms library for buy/sell operations, including deviation control to handle slippage. The strategy employs a new-bar check via the CIsNewBar class to prevent duplicate signals, ensuring only one trading signal per bar period.
Strengths
- Clear trend-following logic using the elliptic filter to smooth price noise and reduce false signals
- New-bar detection mechanism effectively prevents duplicate position openings within the same bar
- Independent control over buy/sell opening and closing provides high flexibility
- Complete stop-loss and take-profit configuration keeps risk manageable
- Uses the TradeAlgorithms library for standardized trading operations, promoting code reuse
Weaknesses
- No spread filter, which may lead to unfavorable fills in high-spread environments
- Stop-loss of 1000 points and take-profit of 2000 points are very wide, unsuitable for all instruments and market conditions
- No position check logic before opening new trades, potentially causing position stacking on repeated signals
- Depends on an external custom indicator file; if the indicator is missing, the EA fails to initialize
- The MM=0.1 parameter meaning is unclear, lacking detailed documentation
Possible improvements
- Add a spread filter mechanism to pause trading when spreads are too wide, avoiding slippage losses
- Add position check logic before opening trades to confirm no existing same-direction positions, preventing position stacking
- Add a trailing stop feature to lock in profits as the trend continues
Risk assessment
Overall risk: Medium
- No spread filter may cause severe slippage in low-liquidity markets
- Lack of position check may lead to repeated same-direction openings, amplifying risk exposure
- Fixed stop-loss and take-profit distances are not self-adaptive to market volatility
Evaluation scores
Parameters
| Parameter | Default | Description |
|---|---|---|
MM | 0.1 | Deposit share (positive) or fixed lot size (negative) |
MMMode | LOT | Lot sizing mode: fixed lots or margin percentage |
StopLoss_ | 1000 | Stop loss in points |
TakeProfit_ | 2000 | Take profit in points |
Deviation_ | 10 | Maximum price deviation in points (slippage tolerance) |
BuyPosOpen | true | Allow buy position opening |
SellPosOpen | true | Allow sell position opening |
BuyPosClose | true | Allow closing long positions |
SellPosClose | true | Allow closing short positions |
InpInd_Timeframe | PERIOD_H4 | DSS Bressert indicator timeframe |
SignalBar | 1 | Bar index for entry signal |
Similar Trend Following EAs
Backtests are historical simulations and do not guarantee future results. Not financial advice.