Gold Channel Expert
- Experts
- Version: 3.5
- Activations: 5
This Expert Advisor (EA) is a channel-based trend and breakout strategy designed for MetaTrader 5.
The strategy combines a 20-period price channel with a 200-period Simple Moving Average (SMA) to identify potential long and short trading opportunities.
Trading Logic
Buy Setup
A Buy position is opened when:
-
The current price is above the 200-period SMA.
-
The previous candle closed below the middle of the price channel.
-
The current price moves back above the channel midpoint.
-
No existing position is open for the symbol.
This setup is designed to identify a bullish recovery through the center of the channel while the market remains above its long-term average.
Sell Setup
A Sell position is opened when:
-
The current price is below the 200-period SMA.
-
The previous candle closed above the middle of the price channel.
-
The current price moves back below the channel midpoint.
-
No existing position is open for the symbol.
This setup is designed to identify a bearish recovery through the center of the channel while the market remains below its long-term average.
Channel Calculation
The price channel is calculated using the highest high and lowest low of the previous 20 completed candles.
-
Upper Channel: Highest high of the selected channel period
-
Lower Channel: Lowest low of the selected channel period
-
Middle Channel: Average of the upper and lower channel levels
The current candle is excluded when calculating the channel levels.
Stop Loss
For Buy trades:
-
Stop Loss is placed at the current lower channel boundary.
For Sell trades:
-
Stop Loss is placed at the current upper channel boundary.
Take Profit
The EA uses a configurable Risk/Reward ratio.
With the default Risk/Reward setting of 2.0, the Take Profit is calculated at approximately twice the initial distance between the entry price and Stop Loss.
Example
If:
-
Buy Entry = 100
-
Stop Loss = 95
-
Risk = 5 points
-
Risk/Reward = 2.0
Then:
-
Take Profit = 110
Trailing Stop
The EA dynamically manages the Stop Loss using the channel boundaries.
Buy Position
If the lower channel moves above the existing Stop Loss, the EA moves the Stop Loss upward to the new lower channel level.
Sell Position
If the upper channel moves below the existing Stop Loss, the EA moves the Stop Loss downward to the new upper channel level.
This allows the Stop Loss to follow favorable price movement while maintaining the channel-based risk structure.
Position Management
-
Only one position is allowed per symbol at a time.
-
A new trade is not opened while an existing position is active.
-
The EA continuously updates the channel and SMA values on every tick.
-
Trade volume is controlled through the LotSize input.
-
Risk/Reward can be adjusted through the RiskReward input.
Main Parameters
| Parameter | Default | Description |
|---|---|---|
| Channel Period | 20 | Number of previous completed candles used to calculate the price channel |
| SMA Period | 200 | Period of the long-term Simple Moving Average |
| Lot Size | 0.10 | Trading volume |
| Risk/Reward | 2.0 | Target reward relative to initial risk |
| Slippage | 10 | Maximum allowed deviation setting |
Strategy Characteristics
This EA is designed around three core concepts:
1. Channel Structure
Identifies the recent trading range using upper, lower and middle channel levels.
2. Long-Term Trend Filter
The 200-period SMA determines whether the EA looks for bullish or bearish setups.
3. Dynamic Risk Management
Initial Stop Loss is based on the channel boundary, while the Stop Loss can subsequently trail as the channel moves.
The strategy can be used on different symbols and timeframes, but its performance may vary significantly depending on market conditions, volatility, spread and timeframe.
Important: This EA is a mechanical trading system and does not guarantee profits. Users should thoroughly backtest and forward-test the strategy with their broker, symbol and trading conditions before using real funds.
