Exp_AltrTrend_Signal_v2_2
This EA trades based on signals from the AltrTrend_Signal_v2_2 custom indicator, which identifies trend direction changes. It opens buy positions on upward trend signals and sell positions on downward trend signals, with configurable stop loss, take profit, and position sizing based on a share of the deposit.
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
The core strategy of this EA is a trend-following trading system based on the AltrTrend_Signal_v2_2 custom indicator. Entry conditions: when indicator buffer 1 (UpValue) shows a non-zero, non-EMPTY_VALUE value on the specified signal bar, a buy signal is generated; when indicator buffer 0 (DnValue) shows a valid value, a sell signal is generated. Exit conditions operate in two ways: first, through reverse signal closing (a buy signal triggers short position closure, a sell signal triggers long position closure), and second, through fixed stop loss and take profit levels in points. Position sizing uses a deposit share-based method controlled by the MM parameter, supporting both LOT and MARGIN calculation modes. For money management, the EA searches backward through historical bars for the most recent reverse signal to determine whether position closing is needed when no direct reverse signal exists on the current bar. The strategy includes a new bar detection mechanism via the CIsNewBar class to prevent repeated trading within the same bar, but lacks scaling in or scaling out logic for position management.
Strengths
- Clear strategy logic based on trend-following signals with well-defined direction
- Flexible position sizing that dynamically adjusts lot size based on deposit share
- Independent configuration of buy/sell open and close permissions for granular trade control
- New bar detection mechanism prevents repeated entries within the same bar
- SignalBar parameter allows flexible selection of signal confirmation delay
Weaknesses
- Depends on the custom AltrTrend_Signal_v2_2 indicator which must be available, making backtesting and deployment less portable
- Lacks spread filtering, which may result in unfavorable fills in high-spread environments
- Backward bar traversal to search for reverse signals may be inefficient on long historical data
- Default StopLoss of 1000 points and TakeProfit of 2000 points are excessively large for most instruments
- Lacks multi-timeframe confirmation and additional filtering conditions, making it prone to false signals
Possible improvements
- Add spread and volatility filters to reduce unfavorable fills and false signals
- Optimize the historical reverse signal search logic by setting a maximum bar search limit to prevent infinite traversal
Risk assessment
Overall risk: Medium
- No spread filter, which may cause slippage losses on high-spread instruments
- Default stop loss and take profit point values are very large, potentially leading to excessive per-trade losses
- Unbounded historical bar traversal may cause execution delays in extreme cases
Evaluation scores
Parameters
| Parameter | Default | Description |
|---|---|---|
MM | 0.1 | Deposit percentage per trade |
MMMode | LOT | Lot calculation method (fixed lot or percentage) |
StopLoss_ | 1000 | Stop loss in points |
TakeProfit_ | 2000 | Take profit in points |
Deviation_ | 10 | Max slippage tolerance in points |
BuyPosOpen | true | Allow buy position opening |
SellPosOpen | true | Allow sell position opening |
BuyPosClose | true | Allow long position closing |
SellPosClose | true | Allow short position closing |
InpInd_Timeframe | PERIOD_H1 | Indicator timeframe |
K | 30 | AltrTrend indicator parameter K |
Kstop | 0.5 | AltrTrend stop loss coefficient |
Kperiod | 150 | AltrTrend K period |
PerADX | 14 | ADX period parameter |
SignalBar | 1 | Bar index for entry signal |
Similar Trend Following EAs
Backtests are historical simulations and do not guarantee future results. Not financial advice.