DTS Portfolio Trend System
- Experts
- Versione: 2.11
- Attivazioni: 5
DTS Portfolio Trend System
A low-frequency trend-following Expert Advisor for the 4-hour chart, designed to trade several uncorrelated instruments from a single chart under one shared risk budget.
How it works
The system has three parts.
1. A daily regime filter. Each day the EA measures the 55-day high and low, lagged one full day so no part of the current day is used. Long entries are permitted only while price is above the upper band, short entries only while price is below the lower band. While price sits inside the band, nothing is traded at all. This neutral zone is the core of the design and is why the system trades rarely.
2. A breakout entry. When the regime permits, the EA enters on an H4 close through the prior 20-bar high or low, filled at the next bar's open.
3. A fixed stop and a channel exit. The stop is placed at 1.5 × ATR(14) measured at the signal bar and does not move. The position is closed when price closes back through the prior 5-bar low (for longs) or high (for shorts).
There is no grid, no martingale, no averaging down, no hedging and no trade without a stop loss.
Portfolio risk governor
Most multi-symbol setups run several copies of an EA, each unaware of the others, each sizing as though it owned the whole account. This EA runs once and enforces limits across all symbols together:
- Daily loss limit — halts new entries for the rest of the broker day
- Maximum drawdown from peak equity — halts the EA entirely for manual review
- Maximum simultaneous positions across all symbols
- Maximum combined open risk as a percentage of equity
- Minimum margin level before any new trade
- Refuses a trade when the broker's minimum lot would risk more than your target, and states the figure in the log rather than silently over-sizing
What this EA is not
Being direct about this saves everyone time:
- It is not a high-frequency or scalping system. Around 12 trades per symbol per year, roughly one a month across three symbols
- It will go weeks with no trades. That is the regime filter working, not a fault
- The backtest contains a stretch of almost three years below a previous equity peak. Long flat periods are the expected experience
- The win rate is under 42%. Most trades lose. The system depends on a small number of large winners
- It is not suitable for a small account on gold. At recent volatility the minimum 0.01 lot risks around $56 per trade, which exceeds 0.35% of a $10,000 account. The EA detects this and skips the symbol with an explanation in the log
- There is no guaranteed or expected return. Results depend on market conditions, your broker's spreads and execution, and your own risk settings
Requirements
- MetaTrader 5, hedging or netting
- H4 and D1 history for every symbol you configure
- A broker offering the instruments you list, with reasonable spreads — the system's edge is roughly six times its modelled transaction cost on H4, so a wide-spread account materially changes the result
- Attach to one chart only. The EA refuses to start if a second instance with the same magic number is detected
Setup
- Attach to a single chart, any symbol, any timeframe
- Enter your broker's exact symbol names in Symbols , with Suffix if your broker uses one
- Set RiskPercent . 0.30–0.35% suits a three-symbol portfolio against a 10% drawdown limit
- Leave the rule inputs at their defaults
The dashboard shows daily P/L, drawdown against the halt level, open portfolio risk, and a per-symbol reason whenever a trade is not taken.
Input parameters, for the listing's parameter section
| Input | Default | Meaning |
|---|---|---|
| Symbols | XAUUSD,USDJPY,EURUSD | Comma-separated, your broker's exact names |
| Suffix | (blank) | Broker suffix such as .raw or m |
| Signal timeframe | H4 | The tested configuration |
| Daily regime length | 55 | Daily Donchian lookback |
| Entry channel | 20 | Breakout lookback |
| Exit channel | 5 | Channel exit lookback |
| ATR length / multiplier | 14 / 1.5 | Stop distance |
| Risk per trade | 0.35% | Of equity |
| Max risk multiple | 1.5 | Skip the trade if the minimum lot forces more than this × target |
| Daily loss halt | 3.0% | Stops new entries for the day |
| Max drawdown halt | 8.0% | Stops the EA entirely |
| Max positions | 2 | Across all symbols |
| Max total risk | 1.0% | Combined open risk |
| Min margin level | 200% | Floor before a new trade |
