Exp_XDerivative
This EA trades based on the XDerivative custom indicator, which calculates a smoothed derivative of price. It opens buy positions when the derivative turns upward and sell positions when it turns downward, with configurable money management and separate buy/sell open/close controls.
Open the interactive view (equity curve, symbol switch)Key facts
Backtest results (H1, about 1 year)
Not backtested yet — this EA could not be converted automatically.
Strategy analysis
The core strategy of this EA is based on the derivative changes of the XDerivative indicator to identify price momentum turning points. Entry conditions: a buy signal is generated when Value[1]<Value[2] (indicator in downtrend) and Value[0]>Value[1] (current value rising), meaning the derivative is turning up from a decline; a sell signal is generated when Value[1]>Value[2] (indicator in uptrend) and Value[0]<Value[1] (current value falling), meaning the derivative is turning down from a rise. This is essentially capturing momentum inflection points, classifying it as a momentum reversal trading strategy. Exit conditions are triggered by opposing signals, with fixed StopLoss and TakeProfit providing risk control. Position sizing supports five modes: percentage of free margin, percentage of balance, percentage of free margin after losses, percentage of balance after losses, and fixed lot size. The indicator uses advanced smoothing algorithms like JJMA to smooth the price derivative, reducing noise but potentially introducing lag.
Strengths
- Uses advanced smoothing algorithms (JJMA etc.) to process price derivatives, effectively reducing market noise
- Independent buy/sell open/close controls provide high strategy flexibility, allowing one-direction-only or close-only modes
- Supports five position sizing modes with comprehensive money management options
- Uses IsNewBar mechanism to prevent repeated trades within the same bar
- Has fixed stop loss and take profit settings for controllable risk
Weaknesses
- Depends on custom XDerivative indicator; EA cannot run if the indicator file is missing
- Default SL of 1000 and TP of 2000 points are large, potentially causing oversized losses in low-volatility markets
- No spread filter, may frequently hit stop loss in high-spread environments
- Signals based on derivative inflection points may generate numerous false signals in ranging markets
- Lacks check for existing positions, potentially opening duplicate trades
- Code comments are garbled (encoding issue), severely hurting readability
Possible improvements
- Add spread filter and volatility filter to avoid opening positions under unfavorable conditions
- Add position check logic to prevent duplicate trades in the same direction
- Add trailing stop functionality to protect profits when in gain
- Change SL/TP to ATR-based dynamic calculation to adapt to different market volatilities
Risk assessment
Overall risk: Medium
- Lacks position check, potentially opening duplicate same-direction trades leading to overexposure
- Fixed SL/TP does not adapt to market volatility changes, may be insufficient during extreme moves
- Depends on external custom indicator; indicator load failure causes EA initialization failure
- No spread filter; high spread environments may erode profits with trading costs
Evaluation scores
Parameters
| Parameter | Default | Description |
|---|---|---|
MM | 0.1 | Money management ratio controlling risk per trade |
MMMode | LOT | Lot sizing mode: free margin/balance/net free margin/net balance/fixed lots |
StopLoss_ | 1000 | Stop loss in points |
TakeProfit_ | 2000 | Take profit in points |
Deviation_ | 10 | Maximum allowed slippage |
BuyPosOpen | true | Allow opening long position on bullish signal |
SellPosOpen | true | Allow opening short position on bearish signal |
BuyPosClose | true | Allow closing long position on reverse signal |
SellPosClose | true | Allow closing short position on reverse signal |
InpInd_Timeframe | PERIOD_H4 | Timeframe for indicator calculation |
i_slowing | 34 | Indicator slowing parameter |
i_price | PRICE_WEIGHTED | Applied price type |
XMA_Method | MODE_JJMA | XMA smoothing algorithm: SMA/EMA/SMMA/LWMA/JJMA/JurX/ParMA/T3/VIDYA/AMA |
XLength | 7 | XMA smoothing depth/period |
XPhase | 15 | XMA smoothing phase parameter |
SignalBar | 1 | Signal reference bar index |
Similar Momentum EAs
Backtests are historical simulations and do not guarantee future results. Not financial advice.