Expert Advisors to control opened trades Risk manager

Expert Advisors to control opened trades Risk manager

21 April 2022, 20:43
Sergey Batudayev
10
366

Good afternoon!


In this article, I would like to talk about Expert Advisors for controlling opened deals in the Risk Manager.

Now I will step by step list the settings of the adviser, what is responsible for what and how it works.  The settings will be listed in the order they appear, from first to last. 


  1. Settings 

Default SL (0-off)

Default TP (0-off)


With these settings, the Expert Advisor can automatically set the SL and TP for you after opening a trade, in case you forgot to do it.


If set to 0, then the Risk Manager will not independently set the SL and TP for your trades, while still continuing to control the risk that you have set. 

  1. Max Lot  Setting

This setting allows you to set the allowed maximum lot

This is a very useful feature that will allow you to control the maximum lot for transactions, if you open a lot more than the one specified in this setting, the adviser will close the deal 



4) Fourth setting  Max Order Same Time 

This setting allows you to set the number of simultaneously open orders in the market, for example, you set the number 2 in the settings, after you open 2 market orders, this means that when you open 3 orders, the adviser will automatically close it immediately.

This setting does not take into account limit orders, it takes into account only those that are already being traded, accounting for simultaneously open orders will begin when limit orders become market ones. 

5) Setting  Delete pending orders 

This setting deletes your pending orders in case of excess of the Day risk (exceeding the risk in the  Max Day Loss settings  )


6) The sixth setting  Calculate with Swap and Commission  when this setting is enabled, losses and profits will be calculated taking into account the swap and broker commissions 


7)  Control Loss & Profit setting -  in this setting you need to choose how you want to control the risk in% or in the account currency, although there is a $ sign here, but it will also work if your account is in euros, rubles, yen or another currency.

8) Setting  Risk Per Trade (0-off)   in this setting you set the risk per trade, you can set both the risk in the account currency $ and the risk in percent.  This setting works in tandem with the  Close Enough Profit / Loss Type setting.  To do this, in the Close Enough Profit / Loss Type settings, set Close Enough Profit / Loss Type  =Trade

9) Close Enough Profit/Loss type= equity/balance - the setting is used so that you can choose how to control the closing of losses and profits, if you select by equity The robot will close positions when the loss / profit on them is higher than the indicated , closing will occur at the moment of exceeding the limits. If you choose by balance, then the robot will calculate the risk after the fact, that is, after you have fixed it and adjust your remaining daily limit accordingly after. Set equity control by default so you can cut your loss even with an open trade.

10) The setting  Calculate Close Day Profit -  Equity / Balance - the setting allows you to set exactly how you want to control DAY profit, by equity or by balance, if you set it by balance, the profit will be controlled after you close the deal.  For example, you set a plan for $500 per day, and chose balance control, then after you close transactions and your daily profit is more than $500, the adviser will not allow more transactions to be kept in the market, it will immediately close them. 


11) The  setting  Max Day Profit (0-off) -  the setting for setting the maximum daily profit, the setting is associated with the 9th setting  Calculate Close Day Profit, if for example this setting has Calculate Close Day Profit=Balance, then after reaching the profit specified in the  Max Day Profit parameter, the EA will immediately close new trades. 


12) Setting Max Orders for Day, allows you to set the maximum number of orders per day, after reaching the specified number, new orders will be immediately closed. 


13)  Loss for Week (0-off)  - maximum loss for a week

13) Loss for Month (0-off) - maximum loss for a month

14) Enable Alerts  - allow alerts or not

15) Interval alerts, min (0-off)  - interval in minutes for alerts, for example, if you set the interval to 30 minutes, then built-in notifications in the adviser will appear 1 time in 30 minutes. 


The EA has an informative panel that displays important statistics



Link to risk manager advisor


Risk manager MT4 -   https://www.mql5.com/en/market/product/72214
Risk manager MT5 -   https://www.mql5.com/en/market/product/72414



Share it with friends: