Skip to main content
Version: 2.0

Configuration

Concept diagram

The concept diagram provided below depicts the function block associated with this page.

Concept diagram, Indicators.png

The indicator module comprises multiple sub-components. The associated input groups for this module are INA1, INA2, INA, INB1, INB2, and INB. The input groups INA1, INA2, INB1, and INB2 correspond to actual indicators and can independently generate signals. You can merge two indicators with the input parameters of INA or INB. The INA and INB parameters allow you to compare indicator values, such as determining which indicator is larger or escalating more rapidly. Further in this document, you will find instructions on establishing a relationship between two indicators and generating a signal based on a standalone evaluation. Please refer to the subsequent illustration demonstrating the functional principle of all submodules related to the indicator module.

Indicators, Concept diagram, Block details 1.png

As is standard with signal generators, only the enabled ones participate actively in the signal generation process. By activating the following input parameters per your requirements, you can alter the internal structure of the indicator module.

Input variable within MetaTrader
(Identifier in SET file)
Default valueComment
> (INA1) CONF, Signal in use
(IN_enmIna1SignalInUse)
OFFNumeric values usable in SET files:
0 - OFF
1 - ON
> (INA2) CONF, Signal in use
(IN_enmIna2SignalInUse)
OFFNumeric values usable in SET files:
0 - OFF
1 - ON
> (INA) CONF, Signal in use
(IN_enmInaSignalInUse)
OFFNumeric values usable in SET files:
0 - OFF
1 - ON
> (INB1) CONF, Signal in use
(IN_enmInb1SignalInUse)
OFFNumeric values usable in SET files:
0 - OFF
1 - ON
> (INB2) CONF, Signal in use
(IN_enmInb2SignalInUse)
OFFNumeric values usable in SET files:
0 - OFF
1 - ON
> (INB) CONF, Signal in use
(IN_enmInbSignalInUse)
OFFNumeric values usable in SET files:
0 - OFF
1 - ON

For instance, if you require INA1 for a SMA-50 calculation, INB1 for a SMA-200, and INB2 for an EMA-50, enable the corresponding submodules and configure the indicator selection. If you wish to evaluate when the SMA-200 line crossed the EMA-50 line, you will also need the INB submodule. Consequently, the internal functional diagram will appear as follows.

Indicators, Concept diagram, Block details 2.png

In general, only the input parameters of enabled submodules are utilized for signal generation. If you wish to turn off an indicator quickly, switch off the submodule instead of resetting all configuration parameters. Please refer to the indicator configuration example for a step-by-step guide on configuring the indicator module.

Drawing of indicator values in chart

The Expert Advisor Builder and Custom Expert Advisor utilize a proprietary trading framework with an indicator engine. This engine eliminates the need to manage executable indicator files externally, a common practice with the MetaTrader trading platform. It addresses key challenges such as seamless switching between indicators and enables the calculation of indicator values independent of symbols and timeframes. The Expert Advisor Builder and Custom Expert Advisor configure your MetaTrader with a chart template employing universal indicators. These universal indicators solely forward the actual indicator value and do not contain the algorithm that generates the output data. Consequently, when you open the indicators list in the strategy tester, you will see the universal indicators applied to the chart.

Indicators, One indicator on chart.png

For this user manual, understanding the exact functioning of this process is unnecessary. The key point is that the Expert Advisor Builder automatically plots the indicator values of all enabled submodules. When executing a trading module with the Custom Expert Advisor, the indicator values are only plotted for the latest loaded trading module. In both cases, enabling the drawing option with the input parameter > (INxx) CONF, Draw in chart is required.

The configuration process for an indicator line is identical across all submodules. This implies that each submodule (INA1, INA2, INB1, or INB2) can execute the same indicator algorithm. The steps are to select the indicator, adjust the algorithm's input parameters, and finally define the condition that must be met for the submodule to be evaluated as a positive trading signal. The input parameters are universally applicable. By default, standard values are internally loaded based on the indicator selection. More details about the configuration of indicator algorithms will be provided later. To simplify this article, it primarily focuses on the indicator submodule INA1 and the INA submodule for combining two indicator lines. However, it's important to note that the configuration process for INA2, INB1, and INB2 is identical to that of INA1 but won't be explicitly detailed here. The same applies to the INA and INB submodules.

Indicators, Concept diagram, Basic signals.png

A trading signal is only forwarded to the order manager when all submodules are evaluated as positive. For instance, you can use INA1, INA2, and INA to generate signals and INB1 to filter those signals for a specific trend.

Enabling of signal, visualization, and drawing of value

As mentioned earlier, only enabled submodules are utilized for signal generation. To enable a submodule, please use the input parameters > (INA1) CONF, Signal in use. By default, an indicator submodule is configured to evaluate its output as a positive trading signal. You can modify when the indicator value is interpreted as a positive trading signal by configuring the condition parameters containing the text snippet COND. Additionally, the final signal of the submodule can be visualized by enabling the input parameters > (INA1) CONF, Signal visualization. Only submodules with enabled drawing features are used to forward the indicator output to the universal indicator and are plotted on the chart. Please refer to the input parameter > (INA1) CONF, Draw in chart for this.

Input variable within MetaTrader
(Identifier in SET file)
Default valueComment
> (INA1) CONF, Signal in use
(IN_enmIna1SignalInUse)
OFFNumeric values usable in SET files:
0 - OFF
1 - ON
> (INA1) CONF, Signal visualization
(IN_enmIna1SignalVisualization)
OFFNumeric values usable in SET files:
0 - OFF
1 - ON
> (INA1) CONF, Draw in chart
(IN_enmIna1DrawInChart)
ONNumeric values usable in SET files:
0 - OFF
1 - ON

The indicator submodule INA1 is configured with a Simple Moving Average (SMA) by default. Therefore, when you enable > (INA1) CONF, Signal in use and > (INA1) CONF, Draw in chart, the SMA indicator line will be visible on the strategy tester chart as green line.

Indicators, Enabling of signal, visualization, and drawing of value, Example charts 1.png
tip

To reproduce the chart from above, you can download and use the SET file package um_eab_cico_6_v_2_0.zip.

As previously mentioned, the submodule, by default, is constantly evaluated as a positive trading signal. You can limit the circumstances under which the indicator generates trading signals by adjusting the condition parameters. However, when > (INA1) CONF, Signal visualization is set to ON, a vertical signal line is drawn behind each bar when the submodule evaluates as a positive signal. It's important to note that these signal lines can be drawn regardless of whether the indicator line is plotted on the chart.

Indicators, Enabling of signal, visualization, and drawing of value, Example charts 2.png
tip

To reproduce the chart from above, you can download and use the SET file package um_eab_cico_7_v_2_0.zip.

Calculated indicator type

Abstraction, a fundamental concept in software development, simplifies complex topics into manageable objectives. In line with this concept, an indicator submodule typically comprises three parts:

  • Part 1: Selection of the indicator type.
  • Part 2: Configuration of the indicator parameters used to configure the indicator algorithm (CONF parameters).
  • Part 3: Adjustment of the conditions under which an indicator value is evaluated as a positive trading signal (COND parameters).

At the onset of the configuration process, you must select the indicator type that the module will use to calculate its output. You can choose from various standard indicators supplemented with custom variations. Please refer to the table below and the input parameter > (INA1) CONF, Selection. As can be inferred, the default value for this submodule is an SMA - Simple Moving Average. This means that this type of indicator is calculated as soon as the submodule is enabled.

Input variable within MetaTrader
(Identifier in SET file)
Default valueComment
> (INA1) CONF, Selection
(IN_enmIna1Selection)
SMA - Simple Moving AverageNumeric values usable in SET files:
0 - PRICE - Price directly from series
1 - SMA - Simple Moving Average
2 - EMA - Exponential Moving Average
3 - HMA - Hull Moving Average
4 - KAMA - Kaufman Adaptive Moving Average
5 - LWMA - Linear Weighted Moving Average
6 - SMMA - Smoothed Moving Average
7 - BB - Bollinger Bands
8 - LREG - Linear Regression
9 - DON - Donchian Channel
10 - PSS - Parabolic Sar Stop
11 - ENV - Envelopes
12 - IKH - Ichimoku Kinko Hyo
13 - PRO - Price Prominence
14 - PIV - Pivot Points
15 - STR - Supertrend

A comprehensive explanation, complete with illustrative examples of each indicator, can be found in the chapter titled Available Indicators and Default Values. By altering the indicator selection, you can easily adjust the algorithm to calculate the indicator value. The examples below demonstrate the usage of the input parameter > (INA1) CONF, Selection. Chart example a) utilizes a SMA - Simple Moving Average, while chart example b) employs an STR - Supertrend. As can be observed, the green indicator line follows a distinctly different shape.

Indicators, Calculated indicator type, Example charts.png
tip

To reproduce the chart from above, you can download and use the SET file package um_eab_cico_8_v_2_0.zip.

For each indicator submodule, the angle is calculated and depicted in a separate chart sub-window beneath the actual price chart. Further down on this page, you can find information on how to evaluate the actual indicator value or the angle of the indicator to generate trading signals.

Each indicator type is accompanied by a default parameter set for the underlying algorithm. When you alter the indicator type, the standard parameters are automatically adjusted to match the selected indicator type. If necessary, you can individually modify these parameters using the input parameters > (INA1) CONF, Parameter 1 till > (INA1) CONF, Parameter 6.

Symbol and timeframe

The table below outlines the input parameters that allow you to specify the symbol and timeframe for an indicator signal generator. The input parameter, > (INA1) CONF, Symbol, can be any symbol from your market watch. By default, it is set to CURRENT, therefore pointing to > (STF) Symbol for 'CURRENT'. If this central symbol selector is also set to CURRENT, the symbol used is the actual chart symbol where the trading module is executed, such as EURUSD. Thus, the STF input parameter primarily serves as the central symbol selector unless > (INA1) CONF, Symbol is set to a symbol name other than CURRENT. This setup allows you to quickly change the primary symbol for the entire trading module using > (STF) Symbol for 'CURRENT' or only the symbol for the indicator module by utilizing > (INA1) CONF, Symbol.

The timeframe selection process mirrors the symbol selection process. If you wish to use a different timeframe for signal generation, you can either modify > (INA1) CONF, Timeframe, or adjust the central timeframe selector > (STF) Timeframe for 'CURRENT'. Changing > (INA1) CONF, Timeframe will cause only the indicator module to use a different timeframe, such as H1, while all other functional blocks will continue to use CURRENT, which could be M15. Altering > (STF) Timeframe for 'CURRENT' will prompt every functional block configured with CURRENT to use the selected main timeframe.

Some symbols provided by brokers may not accurately represent the reference market. For instance, many brokers offer the DE40 index with rates before and after the official market opening and closing. Outside the official market hours, the price is sometimes formed using the future price or third-party market makers to offer a continuous chart in your MetaTrader. This can result in prices that vary from broker to broker, especially during night hours. For many conservative trading strategies, it is desirable to use only the actual market hours to take into account when calculating the indicator values. Therefore, with > (INA1) CONF, Exclusion (HH:MM:SS-HH:MM:SS), you can entirely exclude a given time range. Please note that this feature is not equivalent to the functional block with which you can configure the trading timing of a trading module.

Input variable within MetaTrader
(Identifier in SET file)
Default valueComment
> (INA1) CONF, Symbol
(IN_strIna1Symbol)
CURRENTThe input value cannot be empty.
> (INA1) CONF, Exclusion (HH:MM:SS-HH:MM:SS)
(IN_strIna1Exclusion)
00:00:00-00:00:00The input value has to be in the format HH:MM:SS-HH:MM:SS.
> (INA1) CONF, Timeframe
(IN_enmIna1Timeframe)
CURRENTNumeric values usable in SET files:
-2 - CURRENT
0 - M1
1 - M5
2 - M15
3 - M30
4 - H1
5 - H4
6 - D1
7 - W1
8 - MN

The first set of examples illustrates the effect of changing the > (INA1) CONF, Symbol parameter. In chart a), the symbol is set to CURRENT, while in chart b), it's set to USDCAD. However, both tests were conducted with EURUSD as the symbol. In the example chart b), it's evident that the indicator line based on USCAD is plotted significantly above the actual price chart. These examples were generated using the MetaTrader 5 strategy tester.

Indicators, Symbol and timeframe, Example charts 1.png
tip

To reproduce the chart from above, you can download and use the SET file package um_eab_cico_9_v_2_0.zip.

The following examples show how to exclude a specific period from being used to calculate the indicator values. In chart a), no hours are excluded, so the indicator value is updated throughout the night. In contrast, chart b) excludes the time from 21:00:00 to 08:00:00, resulting in static indicator value during these hours.

Indicators, Symbol and timeframe, Example charts 2.png
tip

To reproduce the chart from above, you can download and use the SET file package um_eab_cico_10_v_2_0.zip.

The final series of examples demonstrate the effect of using a different timeframe. Chart a) uses CURRENT as the timeframe, which means the native timeframe of M15 is used. On the other hand, chart b) uses H1 as the timeframe. This results in different indicator characteristics, as demonstrated with a Simple Moving Average (SMA). In the H1 timeframe, a new candle pattern appears less frequently, so the update of the indicator value happens only every fourth bar.

Indicators, Symbol and timeframe, Example charts 3.png
tip

To reproduce the chart from above, you can download and use the SET file package um_eab_cico_11_v_2_0.zip.

Used series and time shift

The indicator engine allows every algorithm to select from a wide range of data arrays to calculate its output value. This can be achieved using the input parameter > (INA1) CONF, Series. In addition to commonly known data arrays such as OPEN, HIGH, LOW, and CLOSE price, less traditional input data like the size of the current bar body or the upper shadow can also be selected. Some data arrays update with each tick, while others only update when a new bar appears or when a local high or low is reached.

Most indicators come with a standard value for their algorithms. Please refer to the overview of all indicators to see the recommended series. However, most indicator algorithms work perfectly fine with the OPEN series. This price series, which only contains the open prices, updates once when a new bar appears. The second input parameter covered in this section is > (INA1) CONF, Shift. This parameter allows you to shift the entire indicator output by a time range defined in bars.

Input variable within MetaTrader
(Identifier in SET file)
Default valueComment
> (INA1) CONF, Series
(IN_enmIna1Series)
OPENNumeric values usable in SET files:
0 - OPEN
1 - HIGH
2 - LOW
3 - CLOSE
4 - MEDIAN
5 - TYPICAL
6 - WEIGHTED
7 - VOLUME
8 - TIME
9 - BODY
10 - RANGE
11 - SHADOW TOP
12 - SHADOW BOTTOM
> (INA1) CONF, Shift
(IN_nIna1Shift)
0The input value cannot be smaller than 0.

Consider the following example to understand the different effects based on the data arrays selected with > (INA1) CONF, Series. The LOW series typically contains smaller values than the OPEN series, resulting in a slightly lower overall indicator value. Please note that the LOW series only produces accurate indicator values when Every tick is selected for the strategy tester data model. This is particularly important when generating a trading module with the strategy tester.

Indicators, Used series and time shift, Example charts 1.png
tip

To reproduce the chart from above, you can download and use the SET file package um_eab_cico_12_v_2_0.zip.

The following example demonstrates how to shift the entire indicator output by selecting 20 for the input parameter > (INA1) CONF, Shift. Shifting an indicator value has limited practical use in trading, but it can help respond to extremes like lows and highs from the previous bar.

Indicators, Used series and time shift, Example charts 2.png
tip

To reproduce the chart from above, you can download and use the SET file package um_eab_cico_13_v_2_0.zip.

Line index

Specific indicators generate multiple output lines simultaneously. A typical example is the Bollinger Band indicator, which produces three corresponding lines. When an indicator with multiple output lines is selected, the line to be evaluated can be defined using the input parameter > (INA1) CONF, Line index. The available options for line indices for each indicator can be found in the referenced article.

Input variable within MetaTrader
(Identifier in SET file)
Default valueComment
> (INA1) CONF, Line index
(IN_nIna1LineIndex)
0The input value cannot be smaller than 0.

This parameter allows you to use INA1, for instance, to evaluate the lower line of the Bollinger Band indicator and INA2 to evaluate the upper line. The example series below demonstrates selecting a specific line using the > (INA1) CONF, Line index input parameter.

Indicators, Line index, Example charts.png
tip

To reproduce the chart from above, you can download and use the SET file package um_eab_cico_14_v_2_0.zip.

Configuration parameters

Most algorithms used by indicators offer the option to pass parameters to adjust the algorithm that produces the output values. While some indicators only require a simple period input parameter, others may require up to six parameters. The Expert Advisor Builder allows quick indicator switching, facilitating the rapid development of new trading ideas. As such, the input parameters automatically use the most suitable and popular input parameters when you select the indicator line with the input parameters > (INA1) CONF, Selection.

You can find every default parameter for each indicator selection in the indicators overview. Please refer to the associated article to familiarize yourself with the default values. If you wish to use parameter values other than those listed in the indicators overview, you will need to adjust the input parameters > (INA1) CONF, Parameter 1 to > (INA1) CONF, Parameter 6. When all parameters are set to zero, the default values are used.

Input variable within MetaTrader
(Identifier in SET file)
Default valueComment
> (INA1) CONF, Parameter 1
(IN_dIna1Parameter1)
0.0The purpose of the input parameters varies depending on the selected indicator. Please use the indicators overview to identify your > (INA1) CONF, Selection and use the input parameters according to the selected indicator.
If all input parameters are set to 0, the default values for each indicator are in use.
> (INA1) CONF, Parameter 2
(IN_dIna1Parameter2)
0.0
> (INA1) CONF, Parameter 3
(IN_dIna1Parameter3)
0.0
> (INA1) CONF, Parameter 4
(IN_dIna1Parameter4)
0.0
> (INA1) CONF, Parameter 5
(IN_dIna1Parameter5
0.0
> (INA1) CONF, Parameter 6
(IN_dIna1Parameter6)
0.0

To help you understand this feature, please refer to the following example series. As you can see, chart example a) uses the default parameters configured by all zeros. This means it uses 14 for parameter 1, which represents the period. You must adjust these values to use input parameters other than 14. Chart examples b) and c) demonstrate how to use 50 and 120 for the period parameter. The indicator's usage of the input parameters can be found in the indicators overview. Please refer to this page, which contains valuable illustrations of each selectable indicator.

Indicators, Configuration parameters, Example charts.png
tip

To reproduce the chart from above, you can download and use the SET file package um_eab_cico_15_v_2_0.zip.

Signal condition for indicator angle

This page teaches you how to configure the indicator line and select the required line with the index input parameters. The next step involves defining the conditions (COND) that must be met for the indicator line to be interpreted as a valid trading signal. An indicator submodule outputs the indicator value and the angle of the value line. The angle information makes it easy to assess whether a value line is increasing or decreasing.

During testing with the Expert Advisor Builder, you'll notice that a sub-chart window maintains the indicator angle. To evaluate the angle of the selected indicator, please use the input parameters provided.

The input parameters > (INA1) COND, Angle limit condition allow you to define how the angle value should relate to the limit parameters > (INA1) COND, Angle limit 1 and > (INA1) COND, Angle limit 2. These angle limit input parameters are interpreted as pitch rather than an angle value ranging from 0° to 90°. This interpretation facilitates the reuse of this parameter across various assets. Therefore, please interpret the term angle as equivalent to pitch. By default, all angle conditions are disabled, which is one reason the actual indicator signal is always positive.

Input variable within MetaTrader
(Identifier in SET file)
Default valueComment
> (INA1) COND, Angle limit condition
(IN_enmIna1AngleCondition)
OFFNumeric values usable in SET files:
0 - OFF
1 - SMALLER LIMIT 1
2 - GREATER LIMIT 1
3 - EQUALS LIMIT 1
4 - BETWEEN LIMIT 1 AND LIMIT 2
5 - OUTSIDE LIMIT 1 AND LIMIT 2
6 - CROSS LIMIT 1
7 - LIMIT 1 CROSSING
8 - CROSS ANY
> (INA1) COND, Angle limit 1
(IN_dIna1AngleLimit1)
0.0The input value has to be smaller than dIna1AngleLimit2.
The input parameter is interpreted as pitch, not angle, allowing values that can exceed 90° or fall below -90°.
> (INA1) COND, Angle limit 2
(IN_dIna1AngleLimit2)
0.0The input parameter is interpreted as pitch, not angle, allowing values that can exceed 90° or fall below -90°.

The following illustration demonstrates each selectable parameter for the input parameter > (INA1) COND, Angle limit condition with the help of a functional principle diagram and a chart example. Some options involve the input parameters > (INA1) COND, Angle limit 1 and > (INA1) COND, Angle limit 2, while others only use > (INA1) COND, Angle limit 1. As can be seen, the resulting signal output is displayed directly in the chart with the help of the input parameter > (INA1) CONF, Signal visualization.

> (INA1) COND, Angle limit condition = SMALLER LIMIT 1

The indicator angle is evaluated as a positive signal if smaller than > (INA1) COND, Angle limit 1.

Indicators, Signal condition for angle, Angle limit condition = SMALLER LIMIT 0, Principle.png
Indicators, Signal condition for angle, Angle limit condition = SMALLER LIMIT 0, Example.png
tip

To reproduce the chart from above, you can download and use the SET file package um_eab_cico_17_v_2_0.zip.

> (INA1) COND, Angle limit condition = GREATER LIMIT 1

The indicator angle is evaluated as a positive signal if greater than > (INA1) COND, Angle limit 1.

Indicators, Signal condition for angle, Angle limit condition = GREATER LIMIT 0, Principle.png
Indicators, Signal condition for angle, Angle limit condition = GREATER LIMIT 0, Example.png
tip

To reproduce the chart from above, you can download and use the SET file package um_eab_cico_19_v_2_0.zip.

> (INA1) COND, Angle limit condition = EQUALS LIMIT 1

The indicator angle is evaluated as a positive signal if it is precisely the same as > (INA1) COND, Angle limit 1.

Indicators, Signal condition for angle, Angle limit condition = EQUALS LIMIT 0, Principle.png
Indicators, Signal condition for angle, Angle limit condition = EQUALS LIMIT 0, Example.png
tip

To reproduce the chart from above, you can download and use the SET file package um_eab_cico_21_v_2_0.zip.

> (INA1) COND, Angle limit condition = BETWEEN LIMIT 1 AND LIMIT 2

The indicator angle is evaluated as a positive signal if it is between > (INA1) COND, Angle limit 1 and > (INA1) COND, Angle limit 2.

Indicators, Signal condition for angle, Angle limit condition = BETWEEN LIMIT 1 AND LIMIT 2, Principle.png
Indicators, Signal condition for angle, Angle limit condition = BETWEEN LIMIT 1 AND LIMIT 2, Example.png
tip

To reproduce the chart from above, you can download and use the SET file package um_eab_cico_23_v_2_0.zip.

> (INA1) COND, Angle limit condition = OUTSIDE LIMIT 1 AND LIMIT 2

The indicator angle is evaluated as a positive signal if it is outside of > (INA1) COND, Angle limit 1 and > (INA1) COND, Angle limit 2.

Indicators, Signal condition for angle, Angle limit condition = OUTSIDE LIMIT 1 AND LIMIT 2, Principle.png
Indicators, Signal condition for angle, Angle limit condition = OUTSIDE LIMIT 1 AND LIMIT 2, Example.png
tip

To reproduce the chart from above, you can download and use the SET file package um_eab_cico_25_v_2_0.zip.

> (INA1) COND, Angle limit condition = CROSS LIMIT 1

The indicator angle is evaluated as a positive signal if it crosses > (INA1) COND, Angle limit 1.

Indicators, Signal condition for angle, Angle limit condition = CROSS LIMIT 0, Principle.png
Indicators, Signal condition for angle, Angle limit condition = CROSS LIMIT 0, Example.png
tip

To reproduce the chart from above, you can download and use the SET file package um_eab_cico_27_v_2_0.zip.

> (INA1) COND, Angle limit condition = LIMIT 1 CROSSING

The indicator angle is evaluated as a positive signal if it is crossed by > (INA1) COND, Angle limit 1.

Indicators, Signal condition for angle, Angle limit condition = LIMIT 1 CROSSING, Principle.png
Indicators, Signal condition for angle, Angle limit condition = LIMIT 1 CROSSING, Example.png
tip

To reproduce the chart from above, you can download and use the SET file package um_eab_cico_29_v_2_0.zip.

> (INA1) COND, Angle limit condition = CROSS ANY

The indicator angle is evaluated as a positive signal if any crossing of the angle line and > (INA1) COND, Angle limit 1 occurs.

Indicators, Signal condition for angle, Angle limit condition = CROSS ANY, Principle.png
Indicators, Signal condition for angle, Angle limit condition = CROSS ANY, Example.png
tip

To reproduce the chart from above, you can download and use the SET file package um_eab_cico_31_v_2_0.zip.

> (INA1) COND, Angle limit condition = OFF

The indicator angle condition is not in use.

Signal condition for indicator value

The input parameters > (INA1) COND, Value limit condition allow you to define how the indicator value should relate to the limit parameters > (INA1) COND, Value limit 1 and > (INA1) COND, Value limit 2.

Input variable within MetaTrader
(Identifier in SET file)
Default valueComment
> (INA1) COND, Value limit condition
(IN_enmIna1ValueCondition)
OFFNumeric values usable in SET files:
0 - OFF
1 - SMALLER LIMIT 1
2 - GREATER LIMIT 1
3 - EQUALS LIMIT 1
4 - BETWEEN LIMIT 1 AND LIMIT 2
5 - OUTSIDE LIMIT 1 AND LIMIT 2
6 - CROSS LIMIT 1
7 - LIMIT 1 CROSSING
8 - CROSS ANY
> (INA1) COND, Value limit 1
(IN_dIna1ValueLimit1)
0.0The input value has to be smaller than dIna1ValueLimit2.
> (INA1) COND, Value limit 2
(IN_dIna1ValueLimit2)
0.0

The following illustration demonstrates each selectable parameter for the input parameters > (INA1) COND, Value limit condition with the help of a functional principle diagram and a chart example. Some options involve the input parameters > (INA1) COND, Value limit 1 and > (INA1) COND, Value limit 2, while others only use > (INA1) COND, Value limit 1. As can be seen, the resulting signal output is displayed directly in the chart with the help of the input parameter > (INA1) CONF, Signal visualization.

> (INA1) COND, Value limit condition = SMALLER LIMIT 1

The indicator angle is evaluated as a positive signal if smaller than > (INA1) COND, Value limit 1.

Indicators, Signal condition for value, Value limit condition = SMALLER LIMIT 0, Principle.png
Indicators, Signal condition for value, Value limit condition = SMALLER LIMIT 0, Example.png
tip

To reproduce the chart from above, you can download and use the SET file package um_eab_cico_33_v_2_0.zip.

> (INA1) COND, Value limit condition = GREATER LIMIT 1

The indicator angle is evaluated as a positive signal if greater than > (INA1) COND, Value limit 1.

Indicators, Signal condition for value, Value limit condition = GREATER LIMIT 0, Principle.png
Indicators, Signal condition for value, Value limit condition = GREATER LIMIT 0, Example.png
tip

To reproduce the chart from above, you can download and use the SET file package um_eab_cico_35_v_2_0.zip.

> (INA1) COND, Value limit condition = EQUALS LIMIT 1

The indicator angle is evaluated as a positive signal if it is precisely the same as > (INA1) COND, Value limit 1.

Indicators, Signal condition for value, Value limit condition = EQUALS LIMIT 0, Principle.png
Indicators, Signal condition for value, Value limit condition = EQUALS LIMIT 0, Example.png
tip

To reproduce the chart from above, you can download and use the SET file package um_eab_cico_37_v_2_0.zip.

> (INA1) COND, Value limit condition = BETWEEN LIMIT 1 AND LIMIT 2

The indicator angle is evaluated as a positive signal if it is between > (INA1) COND, Value limit 1 and > (INA1) COND, Value limit 2.

Indicators, Signal condition for value, Value limit condition = BETWEEN LIMIT 1 AND LIMIT 2, Principle.png
Indicators, Signal condition for value, Value limit condition = BETWEEN LIMIT 1 AND LIMIT 2, Example.png
tip

To reproduce the chart from above, you can download and use the SET file package um_eab_cico_39_v_2_0.zip.

> (INA1) COND, Value limit condition = OUTSIDE LIMIT 1 AND LIMIT 2

The indicator angle is evaluated as a positive signal if it is outside of > (INA1) COND, Value limit 1 and > (INA1) COND, Value limit 2.

Indicators, Signal condition for value, Value limit condition = OUTSIDE LIMIT 1 AND LIMIT 2, Principle.png
Indicators, Signal condition for value, Value limit condition = OUTSIDE LIMIT 1 AND LIMIT 2, Example.png
tip

To reproduce the chart from above, you can download and use the SET file package um_eab_cico_41_v_2_0.zip.

> (INA1) COND, Value limit condition = CROSS LIMIT 1

The indicator angle is evaluated as a positive signal if it crosses > (INA1) COND, Value limit 1.

Indicators, Signal condition for value, Value limit condition = CROSS LIMIT 0, Principle.png
Indicators, Signal condition for value, Value limit condition = CROSS LIMIT 0, Example.png
tip

To reproduce the chart from above, you can download and use the SET file package um_eab_cico_43_v_2_0.zip.

> (INA1) COND, Value limit condition = LIMIT 1 CROSSING

The indicator angle is evaluated as a positive signal if it is crossed by > (INA1) COND, Value limit 1.

Indicators, Signal condition for value, Value limit condition = LIMIT 1 CROSSING, Principle.png
Indicators, Signal condition for value, Value limit condition = LIMIT 1 CROSSING, Example.png
tip

To reproduce the chart from above, you can download and use the SET file package um_eab_cico_45_v_2_0.zip.

> (INA1) COND, Value limit condition = CROSS ANY

The indicator value is evaluated as a positive signal if any crossing of the value line and > (INA1) COND, Value limit 1 occurs.

Indicators, Signal condition for value, Value limit condition = CROSS ANY, Principle.png
Indicators, Signal condition for value, Value limit condition = CROSS ANY, Example.png
tip

To reproduce the chart from above, you can download and use the SET file package um_eab_cico_47_v_2_0.zip.

> (INA1) COND, Value limit condition = OFF

The indicator value condition is not in use.

Combining two indicators

So far, you've learned how to use the indicator angle and value as standalone signal generators. While this is sufficient for generating proper signals in many cases, there are instances where it's necessary to combine two indicator lines. This is where the submodules INA and INB come into play. These functional blocks can process the output of two indicator lines each. Specifically, INA combines the value and angle lines from INA1 and INA2, while INB combines the value and angle output of INB1 and INB2.

Indicators, Concept diagram, Combined signals.png

Consider the following use case for better understanding. Suppose you have a diagram containing an SMA and an EMA indicator and want to generate a signal every time these indicator lines cross. In this case, you would need to configure the INA submodule, assuming the SMA is generated by INA1 and the EMA by INA2.

Indicators, Two indicators on chart.png
tip

To reproduce the chart from above, you can download and use the SET file package um_eab_cico_49_v_2_0.zip.

As with any submodule, the entire INA submodule can be turned on or off using the input parameters > (INA) CONF, Signal in use. The submodule and all its input parameters are considered for signal generation only if this parameter is set to ON. The signals generated by this submodule can be visualized as vertical lines by enabling the input parameters > (INA) CONF, Signal visualization.

Input variable within MetaTrader
(Identifier in SET file)
Default valueComment
> (INA) CONF, Signal in use
(IN_enmInaSignalInUse)
OFFNumeric values usable in SET files:
0 - OFF
1 - ON
> (INA) CONF, Signal visualization
(IN_enmInaSignalVisualization)
OFFNumeric values usable in SET files:
0 - OFF
1 - ON

Whenever the submodule produces a positive signal, it can be displayed using the > (INA) CONF, Signal in use input parameters. This is particularly useful when sketching a trading idea with the visual mode of the strategy tester. Another use case is to use a trading module to support manual trading by drawing potential trade opportunities onto your chart. The image below shows two example charts with this option, both enabled and disabled.

Indicators, Combining of two indicators, Example charts.png
tip

To reproduce the chart from above, you can download and use the SET file package um_eab_cico_50_v_2_0.zip.

Relation between two indicators

Just as with the evaluation of indicator value and angle, you can use a dropdown menu to determine how the value or angle of indicator INA1 should relate to that of INA2. You can choose up to two relations that must be met to generate a positive output signal. The input parameters > (INA) COND, Relation 1 INA1 to INA2 and > (INA) COND, Relation 2 INA1 to INA2 function identically. Please refer to the table below to familiarize yourself with all the selectable options. As previously mentioned, the submodules INA and INB function identically, even though they use different indicator submodules as input. Therefore, this documentation omits an explicit explanation of INB.

It's important to note that this submodule requires input from both INA1 and INA2, so both submodules must be activated. If they're not, the Expert Advisor Builder will display a warning in the log window.

Input variable within MetaTrader
(Identifier in SET file)
Default valueComment
> (INA) COND, Relation 1 INA1 to INA2
(IN_enmInaRelation1)
OFFNumeric values usable in SET files:
0 - OFF
1 - VALUE 1 EQUALS VALUE 2
2 - VALUE 1 SMALLER VALUE 2
3 - VALUE 1 GREATER VALUE 2
4 - VALUE X CROSS VALUE X
5 - VALUE 1 CROSS VALUE 2
6 - VALUE 2 CROSS VALUE 1
7 - ANGLE 1 EQUALS ANGLE 2
8 - ANGLE 1 SMALLER ANGLE 2
9 - ANGLE 1 GREATER ANGLE 2
10 - ANGLE X CROSS ANGLE X
11 - ANGLE 1 CROSS ANGLE 2
12 - ANGLE 2 CROSS ANGLE 1
The input value can only be used if enmIna1SignalInUse and enmIna2SignalInUse are on.
> (INA) COND, Relation 2 INA1 to INA2
(IN_enmInaRelation2)
OFFNumeric values usable in SET files:
0 - OFF
1 - VALUE 1 EQUALS VALUE 2
2 - VALUE 1 SMALLER VALUE 2
3 - VALUE 1 GREATER VALUE 2
4 - VALUE X CROSS VALUE X
5 - VALUE 1 CROSS VALUE 2
6 - VALUE 2 CROSS VALUE 1
7 - ANGLE 1 EQUALS ANGLE 2
8 - ANGLE 1 SMALLER ANGLE 2
9 - ANGLE 1 GREATER ANGLE 2
10 - ANGLE X CROSS ANGLE X
11 - ANGLE 1 CROSS ANGLE 2
12 - ANGLE 2 CROSS ANGLE 1
The input value can only be used if enmIna1SignalInUse and enmIna2SignalInUse are on.

The following illustration demonstrates each selectable parameter for the input parameters > (INA) COND, Relation 1 INA1 to INA2 and > (INA) COND, Relation 2 INA1 to INA2 with the help of a functional principle diagram and a chart example.

> (INA) COND, Relation 1 INA1 to INA2 = VALUE 1 EQUALS VALUE 2

> (INA) COND, Relation 2 INA1 to INA2 = VALUE 1 EQUALS VALUE 2

The relation is evaluated as a positive signal if the value line of INA1 is precisely the same as that of INA2.

Indicators, Relation between two indicators, Relation = VALUE 1 EQUALS VALUE 2, Principle.png
Indicators, Relation between two indicators, Relation = VALUE 1 EQUALS VALUE 2, Example.png
tip

To reproduce the chart from above, you can download and use the SET file package um_eab_cico_52_v_2_0.zip.

> (INA) COND, Relation 1 INA1 to INA2 = VALUE 1 SMALLER VALUE 2

> (INA) COND, Relation 2 INA1 to INA2 = VALUE 1 SMALLER VALUE 2

The relation is evaluated as a positive signal if the value line of INA1 is smaller than the value line of INA2.

Indicators, Relation between two indicators, Relation = VALUE 1 SMALLER VALUE 2, Principle.png
Indicators, Relation between two indicators, Relation = VALUE 1 SMALLER VALUE 2, Example.png
tip

To reproduce the chart from above, you can download and use the SET file package um_eab_cico_54_v_2_0.zip.

> (INA) COND, Relation 1 INA1 to INA2 = VALUE 1 GREATER VALUE 2

> (INA) COND, Relation 2 INA1 to INA2 = VALUE 1 GREATER VALUE 2

The relation is evaluated as a positive signal if the value line of INA1 is greater than the value line of INA2.

Indicators, Relation between two indicators, Relation = VALUE 1 GREATER VALUE 2, Principle.png
Indicators, Relation between two indicators, Relation = VALUE 1 GREATER VALUE 2, Example.png
tip

To reproduce the chart from above, you can download and use the SET file package um_eab_cico_56_v_2_0.zip.

> (INA) COND, Relation 1 INA1 to INA2 = VALUE X CROSS VALUE X

> (INA) COND, Relation 2 INA1 to INA2 = VALUE X CROSS VALUE X

The relation is evaluated as a positive signal if the value line of INA1 and INA2 crosses each other.

Indicators, Relation between two indicators, Relation = VALUE X CROSS VALUE X, Principle.png
Indicators, Relation between two indicators, Relation = VALUE X CROSS VALUE X, Example.png
tip

To reproduce the chart from above, you can download and use the SET file package um_eab_cico_58_v_2_0.zip.

> (INA) COND, Relation 1 INA1 to INA2 = VALUE 1 CROSS VALUE 2

> (INA) COND, Relation 2 INA1 to INA2 = VALUE 1 CROSS VALUE 2

The relation is evaluated as a positive signal if the value line of INA1 crosses the value line of INA2.

Indicators, Relation between two indicators, Relation = VALUE 1 CROSS VALUE 2, Principle.png
Indicators, Relation between two indicators, Relation = VALUE 1 CROSS VALUE 2, Example.png
tip

To reproduce the chart from above, you can download and use the SET file package um_eab_cico_60_v_2_0.zip.

> (INA) COND, Relation 1 INA1 to INA2 = VALUE 2 CROSS VALUE 1

> (INA) COND, Relation 2 INA1 to INA2 = VALUE 2 CROSS VALUE 1

The relation is evaluated as a positive signal if the value line of INA2 crosses the value line of INA1.

Indicators, Relation between two indicators, Relation = VALUE 2 CROSS VALUE 0, Principle.png
Indicators, Relation between two indicators, Relation = VALUE 2 CROSS VALUE 0, Example.png
tip

To reproduce the chart from above, you can download and use the SET file package um_eab_cico_62_v_2_0.zip.

> (INA) COND, Relation 1 INA1 to INA2 = ANGLE 1 EQUALS ANGLE 2

> (INA) COND, Relation 2 INA1 to INA2 = ANGLE 1 EQUALS ANGLE 2

The relation is evaluated as a positive signal if the angle line of INA1 is precisely the same as that of INA2.

Indicators, Relation between two indicators, Relation = ANGLE 1 EQUALS ANGLE 2, Principle.png
Indicators, Relation between two indicators, Relation = ANGLE 1 EQUALS ANGLE 2, Example.png
tip

To reproduce the chart from above, you can download and use the SET file package um_eab_cico_64_v_2_0.zip.

> (INA) COND, Relation 1 INA1 to INA2 = ANGLE 1 SMALLER ANGLE 2

> (INA) COND, Relation 2 INA1 to INA2 = ANGLE 1 SMALLER ANGLE 2

The relation is evaluated as a positive signal if the angle line of INA1 is smaller than the angle line of INA2.

Indicators, Relation between two indicators, Relation = ANGLE 1 SMALLER ANGLE 2, Principle.png
Indicators, Relation between two indicators, Relation = ANGLE 1 SMALLER ANGLE 2, Example.png
tip

To reproduce the chart from above, you can download and use the SET file package um_eab_cico_66_v_2_0.zip.

> (INA) COND, Relation 1 INA1 to INA2 = ANGLE 1 GREATER ANGLE 2

> (INA) COND, Relation 2 INA1 to INA2 = ANGLE 1 GREATER ANGLE 2

The relation is evaluated as a positive signal if the angle line of INA1 is greater than the angle line of INA2.

Indicators, Relation between two indicators, Relation = ANGLE 1 GREATER ANGLE 2, Principle.png
Indicators, Relation between two indicators, Relation = ANGLE 1 GREATER ANGLE 2, Example.png
tip

To reproduce the chart from above, you can download and use the SET file package um_eab_cico_68_v_2_0.zip.

> (INA) COND, Relation 1 INA1 to INA2 = ANGLE X CROSS ANGLE X

> (INA) COND, Relation 2 INA1 to INA2 = ANGLE X CROSS ANGLE X

The relation is evaluated as a positive signal if the angle line of INA1 and INA2 crosses each other.

Indicators, Relation between two indicators, Relation = ANGLE X CROSS ANGLE X, Principle.png
Indicators, Relation between two indicators, Relation = ANGLE X CROSS ANGLE X, Example.png
tip

To reproduce the chart from above, you can download and use the SET file package um_eab_cico_70_v_2_0.zip.

> (INA) COND, Relation 1 INA1 to INA2 = ANGLE 1 CROSS ANGLE 2

> (INA) COND, Relation 2 INA1 to INA2 = ANGLE 1 CROSS ANGLE 2

The relation is evaluated as a positive signal if the angle line of INA1 crosses the angle line of INA2.

Indicators, Relation between two indicators, Relation = ANGLE 1 CROSS ANGLE 2, Principle.png
Indicators, Relation between two indicators, Relation = ANGLE 1 CROSS ANGLE 2, Example.png
tip

To reproduce the chart from above, you can download and use the SET file package um_eab_cico_72_v_2_0.zip.

> (INA) COND, Relation 1 INA1 to INA2 = ANGLE 2 CROSS ANGLE 1

> (INA) COND, Relation 2 INA1 to INA2 = ANGLE 2 CROSS ANGLE 1

The relation is evaluated as a positive signal if the angle line of INA2 crosses the angle line of INA1.

Indicators, Relation between two indicators, Relation = ANGLE 2 CROSS ANGLE 0, Principle.png
Indicators, Relation between two indicators, Relation = ANGLE 2 CROSS ANGLE 0, Example.png
tip

To reproduce the chart from above, you can download and use the SET file package um_eab_cico_74_v_2_0.zip.

> (INA) COND, Relation 1 INA1 to INA2 = OFF

> (INA) COND, Relation 2 INA1 to INA2 = OFF

The relation condition is not in use.