Trading signals

On the previous page (Indicators) we added all indicators. If you want to edit your indicators, you simply go back and adjust your indicator's parameters. Next, you can create the trading signals ('signals') you want to use for the opening or closing of an order. A signal is a group of conditions which have to be met before an order is opened or closed.

Get started

Your EA has 4 signal types.

  • Open Buy
  • Open Sell
  • Close Buy
  • Close Sell

Signals are a very powerful tool to create almost any Open- and Close logic you can think of. Creating a signal may seem quite difficult in the beginning, but we believe that anyone can master building signals within a week. So please be persistent in learning how to create signals. You can always reach out to us to ask us how to create your signal if you don't know how to proceed, even after reading this page. Also, if you think the signal editor is too limited for your goals, please reach out to us, because we'll show you how you can achieve your goals anyway. We're got a lot of experience in solving complex scneario's. Just use the contact form , or mail us on .

Enable or Disable a signal

You can enable or disable a signal by clicking on the options button and select Enable/Disable. When your signal is disabled it will not be available in the generated output (mql or compiled). The EA needs at least one enabled Open Buy or Open Sell signal to open any orders automatically.

  • Enabled signals appear normal with a vertical blue bar in front of the signal name.
  • Disabled signals are grayed out with a vertical gray bar in front of the signal name.
enable or disable a signal
Click the option button to Enable/Disable a signal. Disabled signals are grayed out.

Copy and Paste a signal

Open the options menu to Copy and Paste a signal to the other types of signal. A common scenario is that you start by creating the Open Buy Signal. When ready, you may want to copy the Open Buy signal to the Close Sell signal and you may want to copy the Open Sell signal to the Close Buy signal. This way the open order will switch from a buy order, to a sell order and vice versa.

  • Open the options menu for a particular signal.
  • Click Copy.
  • Open the options menu for a other signal
  • Click Paste.
copy and paste a trading signal
Click the option button to copy/paste a signal

Invert a signal

Open the options menu to invert a signal. A common scenario is that you start by creating the Open Buy Signal. When ready, you will want to create the Open Sell signal, which is the same as the Open Buy signal, but then Inverted. To do so, click the Invert button on the Open Sell signal after you copied the signal from the Open Buy signal. Make sure that you verify that the inverted signal is what you expect it to be.

invert a trading signal
Click the option button to invert the selected signal

Edit a signal

Click on a signal that you would like to edit. This will open the signal editor. If you started your EA based on a template then some signals may already contain some conditions. Some other signals may be blank and contain only a single node. Start building your signal from this root 'node'.

edit a signal
Click on the signal to start editing.

ANY | ALL Root Group

The root Group gives you a choise between ANY/ALL. This option effects all conditions that are directly in this Group.

  • ANY: Only one of the conditions has to be met for the signal to activate.
  • ALL: All of the conditions have to be met for the signal to activate.
Start building your condition(s) from this root Group.

root logical operator
A signal has 1 root ANY/ALL Group

Add condition

Open the options menu of a ANY | ALL group and select Add Condition. Alternatively, when the group is still empty, you can select an option from the shortcut bar. The shortcut bar will disappear after you add a condition. After you click Add Condition a simple condition will be added.

add condtion
Add a condition. Behind the context menu, there is the shortcut bar.

A condition is an expression with a Left-Hand side, an operator and a right Right-Hand side. By default, the Left- and Right-handside operands are indicators. The indicators you've added to your EA will appear here. You can replace the Indicator with a Function (Bid, Ask, Stoploss etc) or a constant value.

condition added
A simple condition with default Indicator values has been added. ADX is the name of the indicator. Main is the name of the MODE. S0 is the Shift (Bar) on which the indicator will be calculated

Toggle Indicator, Function or Constant

You can toggle between an indicator, function or constant. Click on the element you would like to edit and a popup window will appear.

  • Click on Indicator to access the indicators you have created.
  • Click on Function to access functions like ask, bid, hour, minute etc.
  • Click on Constant to add a constant value. The default value is EMPTY which represents a MetaTrader empty value, which is a long number (2147483647).
toggle between indicator, function and value.
Toggle between indicator, function and value

Shift (Bar)

For each indicator you use in your condition you have to select the Shift you want to use. By doing this, you specify which bar's value (of the indicator) you want to use.

  • Shift (Bar): 0 - The current bar
  • Shift (Bar): 1 - The previous bar
  • Shift (Bar): 2 - The bar before the previous bar, etc.
Select on which bar the indicator will be calculated
Select which bar's value you want to use

Operator

There are three operator categories:

  • Comparison
  • Crossover
  • Mathematical
Each category contains different operators. Depending on the context certain operator categories may not be available. Click here for a full list of available operators.

toggle between Logical, Comparison, Crossover and Arithmetic operators
List of operators can vary based on context.

Add Advanced Condition

If a simpel Condition does not meet your requirements you can add a Advanced Condition.

add advanced condtion
Add a Advanced Condition

A Advanced Condition can contain various elements.

  • Operation
  • Value
  • Mathematical Operator

add advanced condtion
Elements that can be added to a advanced condition. You need to define a Left-Hand side and Right-Hand side operand to complete the Advanced Condition
The Advanced Condition supports all the requirements you may have. Here you can apply complex mathematical operations if needed.
advanced condition example
An example of a Advanced Condition. The Left-Hand side contains an Operation. The Right-Hand side exist of a Mathematical Operator. The Mathematical Operator Contains 2 Operations and 1 Value
When you are done with the Advanced Condition it can be collapsed. A summary of your condition will be shown, this will help you to keep a good overview of your signal.
add condtion
Collapse your Advanced Condition, a summary will be shown.

Add Group Any/All

You can add a nested Group of Conditions. Click on Add Group.

remove node
Add a Group of conditions
Here you can add more Condtions, Advanced Conditions or another nested Group.
remove node
An example of a nested Group. Any of the conditions need to be met, if so, the nested group is met.

Remove node

You can remove a node by selecting "Remove" under options. The root Group (Any/All) can never be removed. Nested Groups can be removed.

remove node
Click remove to remove the node.

Move | Cut-Copy-Paste

There are 2 ways to move elements.

  • Move a condition Up/Down
  • Cut and Paste
  • Copy and Paste
  • Move a node within its container (Group or Advanced Condition) by opening the options menu. Click on Move Up or Move Down to move the element Up or Down in order.
    move node
    Move Condition Up
    If you need to move a node to another container (Group or Advanced Condition), open the options menu and select Cut. The interface will be blocked for editing and you will be presented with options to paste your node. Click on the Paste button where you would like to move this item. The item will be moved to this location. Alternatively, you can use Copy instead of Cut to duplicate the node.
    paste node
    Click on a Paste button to move the Condition to that container. Click cancel to cancel this Cut or Copy action.

    Invalid signals

    When you are building signals you can create a signal that is invalid. Invalid signals cannot be saved. You know that your signal is invalid when you see the exclamation mark with an error message in the top summary box.

    an invalid signal
    A Advanced condition is missing a Left-Hand and Right-hand side operand. Add those elements to fix this error.

    Nested conditions

    You can make signals as complex as you would like. To easily understand how signals work, a good strategy is to divide them into groups. Each group returns true or false.

    complex signal
    Divide signals into groups. We have got 2 blue conditions in the root group and 2 green conditions in the nested ANY/ALL group. Each group returns true or false. One out of 2 green conditions must be true because it is a ANY group. The root group is an ALL group and therefore both blue conditions need to be true, and 1 condition out of the green nested group, for the signal to activate.

    Operators

    The signal editor enables you with a set of well known operators. We've added a set of special crossover operators to make things easier.

    SymbolNameCategory
    crossoverCrossCrossover
    crossover upUp CrossCrossover
    crossover downDown CrossCrossover
    ==EqualComparison
    !=Not EqualComparison
    >=Above or EqualComparison
    <=Below or EqualComparison
    >AboveComparison
    <BelowComparison
    +AddMathematical
    -SubstractMathematical
    /DivideMathematical
    *MultiplyMathematical
    %ModuloMathematical

    Cross

    Use this operator if the direction of the crossover does not matter.

    crossover any example
    If MA 7 crosses over MA 30 the signal will activate. It does not matter from which direction MA 7 crosses over MA 30.

    Up Cross

    Use this operator if the direction crosses over from below (Up Cross).

    Up Cross example
    If MA 7 crosses over MA 30 from below the signal (Up Cross) will activate.

    Down Cross

    Use this operator if the direction crosses over from above (Down Cross).

    Down Cross example
    If MA 7 crosses over MA 30 from above (Down Cross) the signal will activate.

    Equal

    Comparison operator. Returns true if both sides of the expression are equal.

    equal example
    If the the value of indicator MA 7 is equal to the value of MA30, the signal will activate.

    Not Equal

    Comparison operator. Condition is met if both sides of the condition are not equal.

    not equal example
    If the the value of indicator MA 7 is not equal to the value of MA30, the signal will tell the EA to Open an order.

    Above Or Equal

    Comparison operator. Condition is met if the left side of the condition is above or equal to the right side of the condition.

    above or equal example
    If the value of indicator MA 7 is above or equal to the value of MA30, the signal will tell the EA to open an order.

    Below Or Equal

    Comparison operator. Condition is met if the left side of the condition is below or equal to the right side of the condition.

    below or equal example
    If the value of indicator MA 7 is below or equal to the value of MA30, the signal will tell the EA to open an order.

    Above

    Comparison operator. Condition is met if the left side of the condition is above the right side of the condition.

    above than example
    If the value of indicator MA 7 is above the value of MA30, the signal will tell the EA to open an order.

    Below

    Comparison operator. Condition is met if the left side of the condition is below the right side of the condition.

    below example
    If the value of indicator MA 7 is below the value of MA30, the signal will tell the EA to open an order.

    Add

    Use this operator to add numbers.

    add example
    If the value of indicator MA30 + 0.75 is above than the value of MA7, the signal will tell the EA to open an order.

    Substract

    Use this operator to substract numbers.

    subscract example
    If the value of indicator MA30 - 0.75 is above than the value of MA7, the signal will tell the EA to open an order.

    Divide

    Use this operator to divide numbers.

    devide example
    If the value of indicator MA30 divided by 0.75 is above than the value of MA7, the signal will tell the EA to open an order.

    Multiply

    Use this operator to multiply numbers.

    multiply example
    If the value of indicator MA30 multiplied by 0.75 is above than the value of MA7, the signal will tell the EA to open an order.

    Modulo

    Returns the remainder after a division.

    modulo example
    If the remainder of indicator MA30 % 2 = 0, the signal will tell the EA to open an order.

    Functions

    The signal editor provides the flexibility to apply various functions when specifying your conditions. Below is a description of the available functions.

    Price

    The price category of functions give information about the current price, based on your symbol.

    • Ask: the current price requested by your broker.
    • Bid: the current price offered by your broker.
    • Pip: the value of 1 pip. For EURUSD this is 0.0001.

    Account

    The account category of functions give information about your account.

    • Balance: the current balance of your account.
    • Equity: the current equity (balance + floating profit(s)) of your account.

    Date

    The Date category of functions give information about the date- and time functions.

    • Day of month: a number between 1 and 31. Each month, it begins with the value 1 and ends with a number between 28 and 31, depending on the length of the month.
    • Day of week: a number between 1 (Monday) and 7 (Sunday).
    • Day of year: a number between 1 (1st of January) and 365 or 366 (31st of December).
    • Hour: a number between 0 (0 am) and 23 (11 pm).
    • Minutes: a number between 0 and 59.
    • Month of year: a number between 1 and 12.
    • Seconds: a number between 0 and 59.

    Order

    The Order category of functions give information about open orders.

    • No. of open orders: the total number of currently open orders (buy and sell).
    • No. open buy orders: the total number of currently open buy orders.
    • No. open sell orders: the total number of currently open sell orders.
    • Open price: the price at which the order was opened. When used in the context of a signal, it's the last buy or sell order (depending on type of signal). When used in the context of a TP/ SL module, it's the order being evaluated.
    • Open price highest: the highest open price price at which any open order was opened.
    • Open price highest buy: the highest open price price at which any open buy order was opened.
    • Open price highest sell: the highest open price price at which any open sell order was opened.
    • Open price lowest: the lowest open price price at which any open order was opened.
    • Open price lowest buy: the lowest open price price at which any open buy order was opened.
    • Open price lowest sell: the lowest open price price at which any open sell order was opened.
    • Open price newest: the price at which the newest open order was opened.
    • Open price newest buy: the price at which the newest buy open order was opened.
    • Open price newest sell: the price at which the newest sell open order was opened.
    • Open price oldest: the price at which the oldest open order was opened.
    • Open price oldest buy: the price at which the oldest buy open order was opened.
    • Open price oldest sell: the price at which the oldest sell open order was opened.
    • Open price closed: the price at which the most recent closed order was opened.
    • Open price closed buy: the price at which the most recent closed buy order was opened.
    • Open price closed sell: the price at which the most recent closed sell order was opened.
    • Close price: the price at which the most recent closed order was closed.
    • Close price buy: the price at which the most recent closed buy order was closed.
    • Close price sell: the price at which the most recent closed sell order was closed.
    • Open seconds: the duration, in seconds, since the order was opened. When used in the context of a signal, it's the last buy or sell order (depending on type of signal). When used in the context of a TP/ SL module, it's the order being evaluated.
    • Open seconds newest: the duration, in seconds, since the newest open order was opened.
    • Open seconds newest buy: the duration, in seconds, since the newest open buy order was opened.
    • Open seconds newest sell: the duration, in seconds, since the newest open sell order was opened.
    • Closed seconds: the duration, in seconds, since the last closed order was closed.
    • Closed seconds buy: the duration, in seconds, since the last closed buy order was closed.
    • Closed seconds sell: the duration, in seconds, since the last closed sell order was closed.
    • Stop loss: the closest stop loss value set for the order. When used in the context of a signal, it's the last buy or sell order (depending on type of signal). When used in the context of a TP/ SL module, it's the order being evaluated. If no stop loss value is set for the order, it defaults to the Empty value, represented by a long number (2147483647).
    • Stop loss newest: the closest stop loss value set for the newest open order.
    • Stop loss newest buy: the closest stop loss value set for the newest open buy order.
    • Stop loss newest sell: the closest stop loss value set for the newest open sell order.
    • Take profit: the closest target profit set for the order. When used in the context of a signal, it's the last buy or sell order (depending on type of signal). When used in the context of a TP/ SL module, it's the order being evaluated. If no take profit value is set for the order, it defaults to the Empty value, represented by a long number (2147483647).
    • Take profit newest: the closest take profit value set for the newest open order.
    • Take profit newest buy: the closest take profit value set for the newest open buy order.
    • Take profit newest sell: the closest take profit value set for the newest open sell order.

    Next: Modules