Trabajo finalizado
![](https://c.mql5.com/i/avatar/avatar_na2.png)
![](https://c.mql5.com/i/avatar/avatar_na2.png)
Tarea técnica
Hello dear developers!
MT4 EA
I want you to help me create a trading robot. I already had an unpleasant experience with a developer who said he would do it for me but didn't know how to do it. Thus he blocked some money from me.
Now I want to see who knows how to program such a robot. For this reason, I will initially present only a fragment of this robot. Whoever knows how to correctly program this fragment, we will continue to collaborate and make the complete robot.
I want to work together for more trading robots. Of course I will add more money for this.
At the moment, I am strictly interested in this robot fragment, and not other general details from other robots. I want to see clearly, who knows how to program and we will continue to collaborate.
The robot uses a moving average MA (with adjustable period 1...500) and two adjustable levels (1...1000 points), of which one is above the MA, and one is below the MA. The levels are adjusted separately. On Levels completed with "0" or nothing - no transactions are made (they are inactive)!
Example: we assume MA100, with Levels we assume L1 = +200 points, L -1 = -300 points.
L1 = Level above MA.
L-1 = Level below MA.
MA uses: "Shift = 0", "Method = Simple" and "Apply to = Close".
The robot makes Buy transactions when the price goes up from the bottom and reaches a Level. The robot makes Sell transactions when the price drops from top to bottom and reaches a Level. These conditions are valid in all cases (even if the price is below MA or above MA).
When I say that the price is going up or down, I am referring to the previous candle.
On a Level, inside a candle, a single transaction will be made (Buy or Sell). Buy transactions and Sell transactions can be made on the same Level, but on different candles.
No transactions are made if the price reaches the MA.
The robot uses for all transactions on all Levels: a single lot (adjustable 0.01...10), a single TP (adjustable 1...1000 points) and a single SL (adjustable 1...1000 points). For "adjustable", I considered the minimum range but it can be a larger range or infinity!
In order to make transactions, the following two conditions must be met cumulatively:
1. Make transactions only if: any 3 (adjustable 1...50) closed candles or more, from the last 6 (adjustable 1...100) closed candles, do not reach the Level on which the transaction follows (IMG 1). More precisely:
For Buy: at any 3 (adjustable 1...50) closed candles or more, from the last 6 (adjustable 1...100) previous closed candles, the tip of the candles is below the Level and does not touch it. There is also the possibility of an equal number of candles, that is: 1 of the last 1, or 2 of the last 2, or 3 of the last 3..., closed candles.
For Sell: at any 3 (adjustable 1...50) closed candles or more, from the last 6 (adjustable 1...100) previous closed candles, the base of the candles is above the Level and does not touch it. There is also the possibility of an equal number of candles, that is: 1 of the last 1, or 2 of the last 2, or 3 of the last 3..., closed candles.
2. If the price reaches the SL (loss) for Buy, no Buy transactions will be made at that Level, for 3 (adjustable 1...100) closed candles, from the moment the SL is reached. Counting is done without the candle that touched SL.
If the price reaches the SL (loss) for Sell, no Sell transactions will be made at that Level, for 3 (adjustable 1...100) closed candles, from the moment the SL is reached. Counting is done without the candle that touched SL.