Modification of EA and fix some bugs

MQL5 Indicators Experts

Job finished

Execution time 19 days
Feedback from customer
Igor is smart, and software is his thing. He spent days and hours in this business. Even at 3, 4, 5 o'clock at night. Patience may be the right word to describe itself. Thanks.
Feedback from employee
Thanks for task, it was interesting! Wish you all the best!

Specification

Hello Everyone,

I want to make additional additions to the EA I use in my current hand. If it is possible.
Main plugins i want: An add-on to TrailingStop and take profit in case of multi-robot (EA) usage. And minor fixes.
The explanations may be long, to be more descriptive, but I am definitely not talking about a complicated plugin.

Avaliable features - Exists:
--------------------------------
* When the number of positions increases, the following is also increased: step between positions, lot size, take profit (martingale)

With the increase in the number of positions:
the step between positions is increased;
the distance of take profit is increased.
If a signal emerges and the number of positions is equal to the limit, one more position is opened and at the next bar (if there is a signal to open a position)
the most losing position is closed.
Protection of profit: if protection is allowed and the total profit of all positions is greater than the specified value,
as well as the number of positions is greater than or equal to the protected amount, the most profitable position is closed.
For example, we have a total profit of $52 and four open positions. The protected amount is set to "3". So we can close one position,
thus trying to keep a minimum of three positions always open.

This EA's current Input Parameters; (Exists)
** Lots (if <= "0" -> "Risk" is used) - position volume (if <= "0.0", lot "Risk" parameter will be calculated audibly); >>>>Available and used.
** Stop Loss (in pips) - Stop Loss value; >>>>Available and used.
** Take Profit (in pips) - Take profit value; >>>>Available and used.
** Trailing Stop (in pips) - trailing value; >>>>Available and used.
** Trailing Step (min value == 1) (in pip) - trailing step value; >>>>Available and used.
** Percentage risk for a free margin deal - risk per trade as a percentage of free margin; >>>>Available and used.
** Maximum open quotes - the maximum number of open positions (eg = 5) as well as the maximum one-way open position limitation (eg = 3) (Buy or Sell); >>>>Available and used.
** Interval between positions - the distance between positions; (must be in bars.) >>> >>>>Available and used. (it is not working right now.)
** Coefficient interval between positions - multiplier for the step between positions; >>>>Available and used.
** Coefficient Take profit - multiplier for the Take Profit step; >>>>Available and used.
** Min profit. Close max profit position - minimum profit, at which the most profitable position will be closed; >>>>Available and used.
** Account protection. If "true" -> closes max profit position - maintains profit at which the most profitable position will be closed; >>>>Available and used.
** If "account protection" = "true" then number of items open - number of locations to protect; >>>>Available and used.
** Reverse case - reversal signals;  >>>>Available and used. (You can remove this part. I don't need Reverse Signal.)
** Max volume of position - maximum allowed position volume; >>>>Available and used.
** Lot coefficient - lot multiplier, the more open positions exist, the greater lot multiplier will be. >>>>Available and used.
** BenefitK. I have added it. (Maybe in need of some regulation)   >>>>Available and used.
These are Okay.
----------------------------------------------------------------------------------------------------------------------
The Original EA is here: >>>  https://www.mql5.com/en/code/19598. ( I transformed from this orginal EA )

I changed the ZeroLag indicator and just added the MACD Average Signal Line instead.
The indicator i used here: >>>  https://www.mql5.com/en/code/20242


----------------------------------------------------------------------------------------------------------------------

In addition i want;

----------------------------------------------------------------------------------------------------------------------
1-)
The current Classic Trailing Stop and Follow-Up Step is ok. With the additional add-on I want,
after the position is taken to the ground and the classic Trailing Stop is activated,
the following Stop will approach the price as much as the value determined by the input, as well as the value of xx bars (eg = 7 bars).
Let's call this additional plugin BarStep.
Let's call the Bar number to wait after Trailing Stop is activated, Bar
Stop. In this example;
BarStop = 7 Bars
BarStep = 15 points
If I will explain over the sample values ​​here. After Trailing Stop is activated, 7 bars will be expected, nothing will happen.
Meanwhile, only normal Trailing Stop and Trailing Step will be active and will work normally.
After 7 bars, the Trailing Stop level will approach the price by 15 point s at each new bar. (eg BarStep = 15 point s)
The logic here after waiting for a certain period of time (time = bar) and the next stop gets smaller depending on the time (time = bar) and gets smaller with each bar.
Also, keep TralinStep active with the addition of this plugin. Let it run normally.
Both the following step and the Confirmation Step depend on the checkmark. It would be great if that way was possible.
With the Srtategy tester I can optimize and update the values ​​here.
Let's add True - False to this addition. If it doesn't give very good results, let it be disabled. Or if Int BarStep = 0 it means false.
However, in this case, standard Trailing Stop, Trailing step will be active.
Illustrative example:
--------------------
Current price (Example: after 7 bars) = 1.20350 >>> Profit = 350 point s, Guaranteed Profit = 50. (because it is in 50 interval >> 330 - 380 between)
Trailing Stop: 280 pips (1,20050)
Trailing Step: 50
The parameter I want is a new property and name it BarStep = 15 (for example)
Let's assume the price is fixed: 1.20350
8th Bar>> Trailing Stop: 280-15 = 265 points (1,20065) (15 point s slipped up)
9th Bar >> Trailing Stop: 245-15 = 210 pips (1.20080) (15 point s slipped up)
10.Bar>> Trailing Stop: 210-15 = 175 pips (1.20095) (15 point s slipped up)
15. Bar>> Trailing Stop: 175 -15 * 5 = 0 pips (1.20170) (75 point s slipped up)

2-) If this newly modified EA is used at the same time, for example 2 different symbols and 4 different time parameters;
Feature of Multicurrency.
For example: EURUSD 1H, EURUSD 30M, USDCAD 2H and USDCAD 15M (I usually work on 5-digit symbols.)
If the profit of the total calculation for all robots (EA) reaches the level of all = 1000 point s (xxx point s),
then the most profitable xx position (i.e. = 3) and the most losing position (e.g. = 2) I want it to be closed.
It should have the option True-False or it can also mean false (if the value = 0). // --- You can add a comment. It does not matter.
I do not know if 1000 point s are correct logic here. I don't know if point s can be collected in different symbols.
Perhaps instead of fulfilling the requirement to reach 1000 point , a condition of reaching a specified percentage of the Eqquity or balance can also be created.
This part depends on the software developer's decision. (Let me repeat that I usually work on 5-digit symbols.) I didn't know which one would be correct.
Of course a robot takes care of its own trades, usually opening its own trades, closing its own trades. An additional feature I mentioned.
In other words, this new EA I want will be able to intervene in the positions of other robots, regardless of MagicNumber and ticketNumber, when a special requirement is met.
In order for this feature to be added, in addition to 1 special magic number for each new position, the second universal can have an identical magic number!
I think it can be solved this way.

3-) I mentioned above. In addition to the open position limitation as well as the maximum one-way open position limitation (eg = 3) (Buy or Sell)
Total position two way can be xx ( eg = 5 ) but one way positions must be xx ( eg = 3 )

4-) If the profit of open positions reaches the limit of > 0 and for example 600 point s (xxx point ),
I want the feature to then the most profitable xx position (i.e. = 2) and the most losing position (e.g. = 1) I want it to be closed.
for this 1 EA's 1 symbol's magicNumber and this EA robot. And must be True-False options or if value equals = o it is false. (// --- You can add a comment.)
There is this part, but it actually means that the existing benefitK is modified with the eyes of the programmer.

5-) There is an active feature currently in use; (it is some similar to item 4)
"If a signal emerges and the number of positions is equal to the limit, one more position is opened and at the next bar (if there is a signal to open a position)
the most losing position is closed."
I want to change this feature like that;
If a signal emerges and the number of positions is equal to the one-way limit, one more position is opened and at the next bar (if there is a signal to open a position)
the most losing position is closed and with this most benefit position is closed if any.
This the most losing position is closed. ok. But most benefit position is closed if any. Let's add true - Fals to this section, please.

6-) Slippage value is true i dont know! How much must it be? i cant know abut it.
And digit problem; Actually it is seem normal. But there are a problem. i fixed it some like just as follows.
// --- tuning for 3 or 5 digits
   int digits_adjust = 1;
   if (m_symbol.Digits () == 3 || m_symbol.Digits () == 5)
      digits_adjust = 1; <<<<<<(( Originally this number is 10. EURUSD doesn't work properly if you don't set it to == 1 ))
                                  
   m_adjusted_point = m_symbol.Point () * digits_adjust;

   ExtStopLoss = InpStopLoss * m_adjusted_point;
   ExtTakeProfit = InpTakeProfit * m_adjusted_point;
   ExtTrailingStop = InpTrailingStop * m_adjusted_point;
   ExtTrailingStep = InpTrailingStep * m_adjusted_point;
   ExtIntervalPositions = InpIntervalPositions * m_adjusted_point * 10; <<< ((EURUSD doesn't work properly if you don't set == 10 here. İf here 10 everything is ok.))

Can you fix this part please. Because it is not working right.

SL TP lots etc. must work truely in 5 digit symbols. At the same time on 3 digits.

7-) And it constantly opens selling positions. I did not understand the reason for this either. I changed the conditions.
Again, the situation has not changed. I wrote the simple conditions again. The same EA: 174 sell, 14 buy !!! (15M, 10M, 5M) in 15 days.
I don't see anything strange when I examine it. I have examined the Buy-Sell conditions again, it seems like there is no mistake!
Moreover, everything is normal in the strategy test.
I would be glad if you can also look at this topic.

----------------------------------------------------------------------------------------------------------------

You Please submit the final and edited version of the EA file with its open codes, after testing and checking.
Of course, I'll have to retest on the demo account later.

Thank you, and good luck with.

Files:

MQ5
Macd_Av03.mq5
130.5 Kb
MQ5
MSRoC.mq5
5.0 Kb
PNG
Sample01.PNG
200.5 Kb
PNG
Sample02.PNG
47.3 Kb

Responded

1
Developer 1
Rating
(34)
Projects
48
21%
Arbitration
6
83% / 17%
Overdue
8
17%
Free
2
Developer 2
Rating
(170)
Projects
193
11%
Arbitration
37
38% / 35%
Overdue
5
3%
Loaded
3
Developer 3
Rating
(202)
Projects
206
27%
Arbitration
0
Overdue
3
1%
Free
4
Developer 4
Rating
(14)
Projects
19
11%
Arbitration
1
0% / 100%
Overdue
5
26%
Free
5
Developer 5
Rating
(7)
Projects
15
33%
Arbitration
4
0% / 25%
Overdue
3
20%
Free
6
Developer 6
Rating
(42)
Projects
88
14%
Arbitration
30
30% / 53%
Overdue
36
41%
Working
7
Developer 7
Rating
(132)
Projects
170
18%
Arbitration
17
47% / 18%
Overdue
0
Working
Similar orders
Connect from Mt5 via binary deriv account api I have mt5 indicator, need to connect with binary deriv account through api. If anyone can setup via API then contact me. everything control mt5
Hello I am looking for a developer to create an 50% retracement Indicator of the previous candle . So once a candle close the Indicator is supposed to take the full candle size from high to low and make a 61% and 50% level on that candle and I would like the candle to show until the next previous candle is done creating. After this I would look to create an ea with it possibly
Hi, I have 2 indicators which are based on the super trend , the alerts on indicator (1) does not work at all , and on the other indicator the alerts do not come on time on time, which is kind of delayed. see attached file below
Looking for an experienced developer to modify my existing TDI strategy , want to add filter for Buy and Sell Signals, Arrows are displayed on chart and what only to leave high accurate arrows Source code to be provided
I have the mq5 file, I need a buffer adding to the indicator, so it appears in the data window so I can reference it later in an EA. As the below screenshot shows, there is a median ray line from yesterday (the dashed horizontal line) - I want this value in the data window called Median Ray. I want this to be a single value per day, so todays Median Ray would be 17868, and so on each day. So I want all the Developing
I would like to develop my own indicator on metatrader 4 and tradingview. We would start with a basic version that we would improve later. It is an indicator based on several analyses and which would provide several indications. I am looking for someone who can develop on MT4 and Mt5, initially I would like to do it on mt4 and then on mt5. If you have expertise in pinescript it is a plus because I would like to
I urgently require swift assistance to convert a complex indicator into a fully functional scanner, capable of automatically sending real-time data, alerts, and notifications via email, ensuring seamless integration and prompt delivery of critical information to facilitate informed decision-making and timely action
I need to improve the code of an indicator that is too heavy and slow when running and when used with iCustom in an EA. No other changes to the indicator are requested: the original features of the indicator should remain as theay are. I'll provide the indicator after job acceptance. I request final source code mq5 file. Thank you Regards
I have a mt5 indicator that is working perfectly but I will like to make it an expert advisor to have an automated trade. I will be glad if I can get a well experienced developer to execute this project. Thanks
O TRABALHO CONSISTE NA MUDANÇA DO HISTOGRAMA DO INDICADOR TREDN DIRECTION AND FORCE DSEMA SMOOTHED PARA O HISTOGRAMA DA FOTO ANEXA, OBEDECENDO AS TRES CORES VERDE (UP, VERMELHOR(DOWN) E CINZA(TREND). O MESMO TEM QUE ODECER O MESMO CALCULO E COLORIR DA MESMA FORMA POREM COM HISTOGRAMA DDE FORMATO DIFERENTE

Project information

Budget
100 - 200 USD
For the developer
90 - 180 USD
Deadline
to 7 day(s)