工作已完成
指定
I am looking for an experienced MQL5 developer to create an EA based on a grid strategy with hedging capabilities. The EA should operate using the 20-period Simple Moving Average (SMA) as a trend indicator, placing trades based on specific market conditions. Below are the detailed requirements.
EA Features:
1. Initial Trade Logic:
The EA should open an initial buy or sell trade when the price moves above or below the 20-period SMA.
Buy orders are placed when the price is above the 20-period SMA.
Sell orders are placed when the price is below the 20-period SMA.
2. Grid Orders:
If the price moves against the initial trade by a specified grid step (e.g., 20 points), the EA should place additional buy or sell orders at regular intervals.
The grid step should be configurable by the user.
3. Grid Strategy:
Trades are opened only when the price moves in the direction of the trend, based on the 20-period SMA.
Additional grid buy orders are opened if the price is above the 20-period SMA (uptrend).
Additional grid sell orders are opened if the price is below the 20-period SMA (downtrend).
The EA should stop opening grid orders when the price moves against the trend.
4. Lot Size Configuration:
The lot size for each new grid order can be either the same as the initial trade or increased using a configurable GridLotMultiplier.
5. Hedging Mode:
The EA must support hedging, allowing it to open both buy and sell trades simultaneously.
6. Fixed Take Profit for All Orders (No Stop Loss):
All trades (initial and grid orders) should have a fixed take profit level (not averaging).
The take profit level should be configurable and apply uniformly to all open trades.
No stop loss will be used for individual trades or the grid strategy, allowing trades to be managed purely by the take profit.
Users should be able to set the take profit in points, which will close the trade once the target is reached.
Input Parameters:
Initial trade lot size
Grid step (in points)
GridLotMultiplier
Fixed Take Profit for all trades (no stop loss for any trade)
SMA period (default is 20)
Grid order limits (maximum number of grid orders to place)
Additional Requirements:
The EA should work on multiple timeframes and currency pairs.
It should be optimized for both 4 and 5-digit brokers.
The code must be clean, well-commented, and provided in MQL5 format.