The cost of the key is 50 usd

A grid Expert Advisor that collects profit in any direction of price movement!
We catch the initial price movement with stop orders. The exact guidance of the order is carried out by a trawl (pulling it up behind the price). Next, a grid of limit orders is placed at a specified distance (Step) from each other. Moreover, the distance is dynamic and can adjust to the market. The lot is set as a fixed or as a percentage (RiskPercent) of available funds. The essence of the strategy is that the price cannot move forever in one direction without rolling back, and if we did not guess the direction of entry into the market, then it will be averaged and will close in the black at the next pullback. But even with a recoilless movement, the adviser analyzes the situation and places an order in the direction of movement in such a lot that it compensates for drawdowns (locks). Next, the ADVISER closes everything on the accumulation of profit or on the increase in equity….

eurusdh11

On the first screenshot you can see that the Expert Advisor sets orders in both directions from the current price. Notice that at that it has opened two opposite orders – Buy and Sell orders – at once.

eurusdh12


The price goes down, and the Sell order is closed by take-profit. At that several Buy orders are opened. Since the lot size of Buy orders increases as the price goes downwards, a break-even point total for a series of Buy orders approaches to the current price every time the lot size increases. When the price makes a minor pullback upwards, we take profit after the entire series of Buy orders closes.

eurusdh13

Afterwards the price goes a rather long distance downwards again. At that several subsequent Sell orders are closed in profit. When the price makes a pullback upwards again, a series of Buy orders is closed in profit again.

After each close of a series of one-direction orders by total profit, limit-orders of the same direction will be deleted, and a grid of orders of the direction that has been closed will be set again.

The most frightful thing for the Expert Advisor will be a long-sustained pullbackless trend that is established, when global economic problems arise. “OrdersNoTP” parameter will act as an insurance against this pullbackless trend. It enables setting that number of open positions, at which positions of the opposite direction stop to be closed by profit and support positions of this direction that experience a drawdown. If we have 10 open Buy positions (“OrdersNoTP=10”), then open Sell positions will not be closed by profit.

Take-profit will be set from the break-even point total for one-direction orders. Its size can be changed by the Expert Advisor depending on the number of orders. That is, if “деление_профита = true” and “Takeprofit=10”, then take-profit of the first order will be set at the distance of 10 points from the total break-even point, take-profit of the second order will be set at the distance of 5 points, etc. Thus, the more positions are opened in the given direction, the closer the take-profit of these positions will be moved by the Expert Advisor to the current price. However, the entire series of one-direction orders will be always closed in profit.

The Expert Advisor enables setting its time of autotrading, for example: TimeStart= 10, TimeEnd = 22, FridayHourClose = 16. It follows that the Expert Advisor will set new series of orders only from 10 a.m. to 10 p.m. all days except Friday (it will work only up to 4 p.m. on Friday).

In order to get similar results, you need to optimize the Expert Advisor. You can read how to do this here: https://cmillion.ru/optimization/
The cost of the Expert Advisor is 50 USD. Payment methods: https://cmillion.ru/en/pay/

Inputs:

  • Step           = 20;   //distance between orders opened within a grid of orders
  • Lots           = 0.0;   //if=0, then lot size will be calculated as a percentage of free margin set in “RiskPercent %” parameter
  • RiskPercent   = 0.01; //Lots = AccountBalance() * (RiskPercent / 100.0) / 10000.0
  • K_Lot         = 1.5;   //lot multiplier
  • Max_Lot       = 50;   //limits a lot size
  • DigitsLot     = 2;     //number of decimal places in the lot size (2 – 0,01) (1 – 0,1)
  • OrdersNoTP     = 5;     //if this number of orders is exceeded, the Expert Advisor is disallowed to set a take-profit for profitable one-direction orders
  • ProfitClose   = 50;   //profit in deposit currency, by which all orders will be closed
  • Takeprofit     = 35;
  • деление_профита = true;   //take-profit will be divided in a number of open orders
  • VirtualTS     = false; //enables a virtual or a real trailing stop
  • TrailingStop   = 0;     //if 0, then stop-losses will not be trailed
  • OrdersTek     = 3;     //number of open pending orders; it is used to reduce a load on a dealing center

In the updated version 13(14) added trading stop orders together with limit.

Cm-Limit
Cm-Limit
cm-Limit-15.4.ex4
Version: 15.4
58.4 KiB
701 Downloads
Details
Cm-Limit
Cm-Limit
cm-Limit-15.6.ex5
Version: 15.6
57.3 KiB
78 Downloads
Details