Форекс стратегии, торговые роботы, индикаторы

Grid Manual-panel for manual trading with a grid of orders

Trading panel for the MetaTrader 4 platform

Rebate service

ForexMq

RUS
ENG

Grid Manual — is a trading panel for working with grid strategies. The utility is universal, has flexible settings and a clear interface. Works with a grid of orders not only in the direction of averaging losses but also in the direction of increasing profits. The trader does not need to create and maintain a grid of orders, the utility will do it. Just open an order and Grid manual will automatically create a grid of orders for it and will accompany it until it closes.

Main features of the utility:

  • Accompanies orders opened in any way, including from a mobile terminal.
  • It works with two types of grids: limit and stop.
  • It works with two methods for calculating the grid step: fixed and dynamic (based on the ATR indicator).
  • Allows you to change the settings of the open grid, including changing the lot of each level, and its location (you can only move the level in fixed step mode).
  • Displays the breakeven level of each grid on the chart.
  • Shows the profit size of each grid.
  • Allows you to close each grid of orders with a single click.
  • It has a trailing stop function.
  • It has the function of moving the stop loss of the order grid to breakeven.
  • Automatically rearranges the take profit relative to the breakeven level of the order grid (only in the limit grid mode, the distance depends on the selected calculation type: Conservative or Aggressive).
  • Saves settings and restores them after restarting the terminal.
  • Supports up to 20 grids, each of which can have up to 100 orders.

Panel control

Panel controls

  1. The capture zone for the mouse to move the bar.
  2. Tab to configure settings for the utility.
  3. Button for minimizing the panel.
  4. Tab for opening orders.
  5. Tab for closing the order grid.
  6. Tab to render the grid levels of orders.
  7. Tab for configuring parameters of the open order grid.

The utility is a panel consisting of 5 tabs. You can switch between tabs by pressing buttons 2, 4 - 7.

Settings tab, basic operating principles

Settings tab

Settings are divided into three groups: Grid, Tp/Sl, and Lots.

  1. Button to go to the settings tab.
  2. Settings for the grid step and number of levels.
  3. Setting up order grid tracking.
  4. Настройки лота.

This tab contains the settings that will be used to build and control each new order grid. These settings are assigned to each new grid once, at the time of its creation. Changing the settings on this tab does not affect the settings of already opened order grids.

Important! You can change the settings for already opened order grids only from the MG tab.

Settings tab: Grid

Tab for setting the step and number of orders in the grid

The size of the panel and the set of parameters depends on the "Step Type"parameter.

  1. Grid type (Limit or Stop).
  2. Method for calculating the step size (Fixed or ATR).
  3. Timeframe for the ATR indicator (ATR method).
  4. Period for the ATR indicator (ATR method).
  5. Multiplier for the step (ATR method).
  6. The minimum step (ATR method).
  7. The number of steps in the grid.
  8. Step size (Fixed method).

Order grid type

The utility can work with two types of grids. The grid type is set by the Grid type parameter:

Grid type — Limit

Limit — the grid is built from BuyLimit or SellLimit orders, and is directed to the unprofitable side of the first order. This type is used in strategies with loss averaging.

Grid type — Stop

Stop — the grid is built from BuyStop or SellStop orders, and is directed to the profitable side of the first order. This type is used in strategies with increasing profits.

The utility opens the corresponding pending order at the level closest to the current price. After its execution, the next pending order is opened at the next level.

You can disable the use of pending orders by switching the Pending order input parameter to false. In this mode, the utility will not open pending orders, and when the Ask or Bid price touches the next level, the utility will open a Buy or Sell position.

Attention! When building a grid of orders directly with Buy and Sell positions, price slippage may increase during execution. Therefore, for error-free grid construction, set the grid step to at least three times the size of the slip set in the input parameter Slippage. For example, if the Slippage = 30 points, the grid step must be at least 30*3=90 points.

Step size

The step size calculation depends on the Step type parameter, and is performed using one of the following methods:

Fixed step size

"Grid step" = 200, the grid of orders will be built in increments of 200 points.

Fixed — the step size is fixed and equal to the Grid step parameter.

Step size by ATR

The ATR indicator is equal to 229 points, respectively, the grid step at the time of opening a BuyLimit order will be equal to Step=229*1.5=343 points.

ATR — the step size is dynamic and depends on the ATR indicator: Step=ATR*Coefficient. The step is recalculated and the grid is rebuilt before opening each new pending order. To control the minimum step size, a parameter is provided Min. step. If the calculated step is less than the Min. step value, the utility uses the Min. step value for the step.

Settings tab: Tp/Sl

Tp/Sl settings tab

  1. Type of take profit calculation (Aggressive or Conservative, only for the Limit grid type).
  2. Take profit for the grid of orders (in points, 0 — off).
  3. Stop loss for the grid of orders (in points, 0 — off).
  4. Breakeven distance (in points, 0 — off).
  5. Profit for the breakeven function (in points).
  6. Distance to start the trailing stop (in points).
  7. Trailing stop distance (in points, 0 — off).

Take-profit

Take profit for all grid orders is set at the same level.

The calculation of the TP installation level depends on the grid type:

Take profit for the Stop grid

Stop сетка — take profit is set at the distance of Take profit (1) from the last level in the direction of profit. The distance to the take profit is not recalculated and always remains fixed.

Limit сетка — take profit on this type of grid is adaptive and is deferred from the total breakeven level of the order grid. The distance from the breakeven level to the take profit depends on the TP type parameter and can have the following options:

Take profit for Limit grid-Aggressive — Aggressive

Aggressive method: as positions in the grid increase, the take profit in points remains unchanged, and the total profit in currency increases.

Aggressive — aggressive method. The total take profit is deferred from the breakeven level by the distance Take profit (1), while the distance does not change and does not depend on the number of positions in the grid.

The take profit Limit for the grid — Conservative

Conservative method: as positions in the grid increase, the take profit in points will decrease, and the total profit in the currency will remain unchanged.

Conservative — conservative calculation method. The distance from the breakeven level to the take profit is recalculated when opening each new position. The distance is calculated in such a way that when closing the grid of orders by take profit, the total profit of positions will be equal to the profit of the starting position. In other words, the total profit of the grid in the Deposit currency will always be the same, regardless of the total lot volume of grid orders.

Stop-loss

Stop loss for grid orders

The stop loss of all grid orders is set at the same level:

  • For Buy grid — stop loss is set from the last lower level of the grid, at the distance of Stop loss.
  • For Sell grid — stop loss is set from the last upper level of the grid, at the distance of Stop loss.

The breakeven function

Breakeven function

  1. Breakeven distance (in points, 0 — off).
  2. Profit for the breakeven function (in points).

The breakeven function is used for automatically transferring the stop loss of the order grid to the breakeven level. Grid Manual controls each grid separately and moves the stop loss of orders to the breakeven level when the current price of the distance BreakEven Distance (1), deferred from the breakeven level of the grid, is reached. You can shift the stop loss from breakeven to the profitable side, to do this, set the required distance in the BreakEven Profit (2).

The function of trailing stop

The function of trailing stop

  1. Distance to start the trailing stop (in points).
  2. Trailing stop distance (in points, 0 — off).

The trailing stop function moves the stop loss behind the current price, with the specified Trailing Stop (2). The utility applies a trailing stop to each grid separately and is enabled when the current price of the Trailing Start (1), deferred from the breakeven level of the grid, is reached.

Settings tab: Lots

The settings tab of the lot

  1. Lot size for orders that will be opened from the TR tab.
  2. Multiplier for increasing the lot of the grid of orders.

The lot of each grid level increases relative to the previous one by the multiplier specified in field 2.

TR tab

This tab is used for opening and closing orders.

TR (trade) tab

  1. Buttons for opening Buy and Sell orders.
  2. Buttons for displaying line on the chart with a button for opening a pending order (4, 5).
  3. Buttons for deleting all Buy or Sell orders, orders are deleted only from the current instrument that have the same magic number.
  4. The button for opening a pending order is displayed when a button from group 2 is clicked.
  5. Button for deleting the line with the order opening button (4).

How to open an order

To open a Buy or Sell order, click the corresponding button from group 1.

A pending order is opened in two stages:

  1. Click the corresponding button from group 2. when clicked, the utility will display a line with buttons 4 and 5 on the graph.
  2. Move the line to the desired level and click 4. When clicked, the utility opens the corresponding pending order at the line level.

How to open an order

The lot size of open orders will be equal to the Start lot, parameter set on the settings tab. Each order opened in this way, the utility takes under its own supervision. The utility also takes control of all open orders on the instrument that have a magic number equal to the utility's Magiс.

CL tab

This tab is used for closing the order grid.

Tab: CL

Three order grids have been opened, with the numbers 272648310, 272649088 and 272649208.

  1. Buttons to go to closing the order grid.
  2. Button to go to closing the grid #272648310.
  3. Button to go to closing the grid #272649088.
  4. Button to go to closing the grid #272649208.

Sorting (identification) of order grids

The utility can support up to 20 order grids. To sort them, each grid has its own number corresponding to the ticket of the first (starting) order. Each grid order, except the first one, has a comment with the grid number to which it belongs.

Closing the order grid

Go to the order grid closing tab

To close the order grid, click the button with its number. After clicking, the utility switches to the close tab of the selected grid.

Order grid closing tab

Closing the grid of orders with the number 272649088: the grid consists of two Sell and one SellLimit, and has a profit of 0.40$.

  1. The grid number.
  2. Total profit of the order grid, including swap and Commission.
  3. Button for closing the grid.

VG tab

VG tab

  1. Show / hide the levels of all grids.
  2. Show / hide the levels of the specified grid.

The VG tab contains buttons for enabling / disabling the display of grid levels. Levels are displayed as lines, the color and style of which is configured from the input parameters.

MG tab

For each new order, the utility builds a grid of orders according to the parameters from the Settings tab. In the future, you can change these parameters for an open grid on the MG tab.

MG tab

  1. Buttons to go to setting up the order grid.
  2. Button to stop tracking the grid of orders.

Setting up an open order grid

To change the parameters of the order grid, click the button with its number (1). After clicking, the utility switches to the settings tab of the selected grid.

The settings on the MG tab are divided into three groups: Setting, Grid, and Tp/Sl. All changes on this tab will only apply to the selected grid.

MG tab: Setting

MG tab: Setting

  1. The grid number.
  2. Grid type (Limit or Stop).
  3. Method for calculating the step size (Fixed or ATR).
  4. Timeframe for the ATR indicator (ATR method).
  5. Period for the ATR indicator (ATR method).
  6. Multiplier for the step (ATR method).
  7. The minimum step (ATR method).
  8. The number of steps in the grid.
  9. Step size (Fixed method).
  10. Save the changes.
  11. Reset changes.

To save changes, click 11. To reset your changes before the last saved state, click 12.

To temporarily stop tracking the order grid, click 9. When tracking is stopped, all trading operations for this grid of orders are stopped, which means that the utility will not modify the grid positions and will not open new orders for it. To resume trading, click 9 again.

If changes to the grid settings are made when trading is stopped, the changes will only take effect when trading is resumed.

For more information about the parameters of this tab, see the settings Tab: Grid..

MG tab: Grid

MG tab: Grid

  1. Fulfilled levels.
  2. The selected level for adjustment.
  3. Buttons for scrolling the list.
  4. The level selected for configuration.

On this tab, you can change the position of the level and its lot.

How to change the price of the grid level

Setting the level position

To change the position of the grid level, select it in the list of orders. Move the flashing line that appears to the desired location and click SAVE.

Attention! You can only change the level position when Step type — Fixed. When the Step type — ATR position is set, the step is calculated using the Average True Range indicator.
How to change the open grid level lot

Setting the lot size

To change the size of a level lot, double-click its cell and open the input field. Enter the required lot in the field that appears and click SAVE.

MG tab: Tp/Sl

MG tab: take profit, stop loss

  1. Type of take profit calculation (Aggressive or Conservative, only for the Limit grid type).
  2. Take profit for the grid of orders (in points, 0 — off).
  3. Stop loss for the grid of orders (in points, 0 — off).
  4. Breakeven distance (in points, 0 — off).
  5. Profit for the breakeven function (in points).
  6. Distance to start the trailing stop (in points).
  7. Trailing stop distance (in points, 0 — off).

For more information about the parameters of this tab, see the settings Tab: Tp/Sl.

To save the settings, click SAVE.

Input parameters

  • Pending order — on/off use pending orders.
  • Order grid type — direction of the order grid (Limit or Stop).
  • Starting lot — lot size for orders opened from the TR tab.
  • Lot multiplier — multiplier for increasing the lot of the order grid.
  • Step type — method for calculating the step (Fixed or ATR).
  • Grid step (Fixed) — step size (for the Fixed method).
  • Timeframe (ATR) — timeframe for the ATR indicator (for the ATR method).
  • Period (ATR) — the period for the ATR indicator (for the ATR method).
  • Coefficient (ATR) — multiplier for the step (for the ATR method).
  • Min grid step (ATR) — the minimum step (for the ATR method).
  • Number of steps — the number of steps in the grid.
  • Take profit type — the type of take profit calculation (Aggressive or Conservative, used only for the Limit grid type).
  • Take profit (0-off) — take profit for the grid of orders (in points, 0 — off).
  • Stop loss (0-off) — stop loss for the grid of orders (in points, 0 — off).
  • BreakEven Distance (0-off) — distance for breakeven (in points, 0 — off).
  • BreakEven Profit — profit for the breakeven function (in points).
  • Trailing Start — distance to start the trailing stop (in points).
  • Trailing Stop (0-off) — the distance of the trailing stop (in points, 0-off).
  • Attempts to open an order — the number of attempts to open an order if the previous attempt was unsuccessful.
  • Magic number — order ID.the utility uses this number to find its orders.
  • Slippage — the maximum allowed price slippage when opening and closing an order.
  • Buttons market orders on/off — show / hide position opening buttons.
  • Buttons pending orders on/off — show / hide buttons for opening pending orders.
  • Buttons closing orders on/off — show / hide buttons for closing all orders.
  • Show the breakeven level — show / hide the breakeven level of the order grid.
  • Сolor breakeven line — the color of the breakeven line.
  • Style levels — the style of the lines that represent the grid levels.
  • Color active buy levels — the color of the active Buy levels in the grid.
  • Color inactive buy levels — color of inactive Buy levels in the grid.
  • Color active sell levels — the color of active Sell levels in the grid.
  • Color inactive sell levels — color of inactive Sell levels in the grid
  • Color text — the color of the text of the levels..
  • Sound button — sound for the buttons.
  • Sound button user — custom button sound.
  • Sound error — sound for errors.
  • Sound error user — custom sound for errors.
  • Font size on the panel — the font size of the panel text.
  • Font size on the chart — the font size of the text on the chart.

FAQ

Yes, to do this, you need to set the Magiс parameter to 0 in the input settings (Orders opened using the terminal have a magic number = 0).

Yes, to do this, Grid Manual must run on the same tool and have the same "Magic" parameter as the trading robot. But keep in mind that the trading robot does not have to accompany its own orders, otherwise there will be a conflict between the utility and the trading robot. Before launching to a real account, we recommend checking the mutual operation of the utility and the trading robot on a demo account.

Yes.

Yes, all settings and parameters of order grids are saved to a file, and after restarting, they are restored from this file.

This is possible if the text size in the operating system is selected more than 100%. In such cases, use the text size settings in the Font size on the panel and Font size on the chart utility.

In points. The utility uses the MQL definition, the point is the minimum possible change in the price of the exchange rate.

  • 5-digit quote – 1 point = 0.00001.
  • 4-digit quote – 1 point = 0.0001.
  • 3-digit quote – 1 point = 0.001.
  • 2-digit quote – 1 point = 0.01.

Update

Version 1.4 26.05.2020.

  • Added the ability to build a grid in positions without using pending orders.

Version 1.3 22.04.2020.

  • Внимание! Рекомендуем обновлять только после закрытия текущих ордеров. Если вы обновляете утилиту с открытыми ордерами, то после запуска перейдите на вкладку Вкладка MG и проверьте настройки открытых сеток ордеров.
  • Attention! It is recommended to only update after the close of the current orders. If you are updating the utility with open orders, go to the MG Tab after launch and check the settings for open order grids.
  • Added calculation of the grid step based on the ATR indicator.
  • Added the possibility of suspending the support grid of orders.
  • Added the save and reset settings buttons.
  • Changed the panel interface.

Version 1.2 01.09.2019.

  • Внимание! Изменен алгоритм обработки сетки ордеров. Обновляйте утилиту только после закрытия текущих ордеров!
  • Attention! Changed the algorithm of processing the order grid. Update the utility only after closing the current orders!
  • Optimized the code.
  • Added trailing stop.
  • Added transfer to breakeven.
  • Added showing the breakeven level.
  • Added the grid type from stop orders.
  • Added a button for recalculating the stop loss level.

Version 1.1 16.03.2019.

  • Optimized the code.
  • Added methods for calculating take profit.

Download the demo | buy for MT4

Смотреть так же:




Комментарии ()