Job finished
![](https://c.mql5.com/i/avatar/avatar_na2.png)
![](https://c.mql5.com/i/avatar/avatar_na2.png)
Specification
General information
The indicator puts arrows on certain candles and dots on a certain number of preceding candles. The task of the adviser is to open trades on the next candle after the candles with arrows (signal candle).
There should be only one trade per signal candle. Several trades can be opened at the same time due to the fact that there were several signal candles.
In case of slippage, immediately close.
Input parameters
Include both EA and indicator settings
EA
1. Direction - with/against - the direction of the signal candlestick
· with - if the signal candle is bullish then BUY
if the signal candle is bearish then SELL
· Against - if the signal candle is bullish then SELL
if the signal candle is bearish then BUY
2. Basis - signal/candle – parameter measuring signal length
· If signal. The length is measured from max high/min low price of preceding candles (the ones with the dots) or signal candle (depending on what is higher/lower) to signal candle close price
· If candle. The length is measured from max high/min low price of signal candle to signal candle close price
3. Trade from - time when trading starts
4. Trade till - do not open deals after this time. Deals already opened are not affected.
5. Risk % – % of the deposit that is lost if SL is reached
6. Min length – if the length of the signal candle/whole signal (point Basis) is less than this value, then the deal doesn’t open
7. Max length – if the length of the signal candle/whole signal (point Basis) is more than this value, then the deal doesn’t open
8. TP % - X - Basis*X%
9. SL % - X - Basis*X%
10. Breakeven % – transfer the deal to breakeven when % of TP is reached
11. Close trade in - X bars. The trade is closed either at TP/SL or after X bars if TP/SL has not been reached.
12. One trade – yes/no – only one trade per time
13. Magic number
Indicator
Among all the indicator settings that are shown on the following screenshot, we take out only the following
1. Mode – bodies/shades
2. Number of candles
3. Average %
4. Max %
Example
Input parameters
EA
1. Direction – against
So SELL will be opened
2. Basis - signal
· Calculate the length 1.09406 – 1.09258 = 0.00148
· We take the price of 1.09258 because this is the lowest price among the signal candle and the 5 marked preceding candles.
· If Basis = candle then 1.09406 – 1.09302 = 0.00104.
3. Trade from - 1:00
4. Trade till - 23:00
5. Risk % – 0.5
6. Min length – 50
7. Max length – 200
8. TP % - 150
148* 150% = 222 points
1.09406 – 0.00222 = 1.09184
9. SL % - 100
= 148 points
1.09406 + 0.00148 = 1.09554
10. Breakeven % – 110
148*110% = 163 points
1.09406 – 0.00163 = 1.09243. At this price, we transfer the deal to breakeven.
11. Close trade in - 50.
12. One trade – no
13. Magic number -
Indicator
1. Mode –
2. Number of candles – 5. This is the only parameter we need for now. This parameter shows how many previous candles we take into account when calculating the parameter Basis.
3. Average % -
4. Max % -