仕事が完了した
![](https://c.mql5.com/i/avatar/avatar_na2.png)
![](https://c.mql5.com/i/avatar/avatar_na2.png)
指定
Hi, I have an Expert Advisor based on the StepMa indicator and I would like to add 3 functions to it:
1. Dynamic lot size : Add a dynamic lot size calculation.
You can choose between Fix Lot size (the one we currently have) or Dynamic lot size.
If Dynamic lot is True, you are enabling dynamic lot calculation in percent of free margin for the new position.
In this way, when Dynamic is true, the larger the free marging becomes, the larger the size of the initial lot will be.
Here you can see how it is possible to implement a dynamic lot size:
2. Martingale option: If the EA closes the previous positions in loss then the next time the lot size will be multiplied by X. You can choose the value of X in the Expert inputs tab. Once the EA closes the positions in profit we go back to the initial lot size (fix lot size or dynamic lot size calculated from the free margin)
If Martin increase lot is set to 1 then martingale is not enabled.
3. Stop loss. Calculation of the maximun loss in Points. The EA currently closes all positions automatically when the maximun profit in points is reached. I want to add the same function when the total loss in points is reached. You can choose the number of points in loss for closing all the positions. The EA will close all the positions when the total loss in points is reached. Force closure of all positions when the total floating loss is reached.