Expressions

This section explains the types and meanings of expressions, which are central to this product, as they allow you to implement an infinite variety of strategies. In the expression fields, you write mathematical and logical conditions. For example, if you have two moving average indicators and want to execute an action when the first is greater than the second, you should write in the expression field “MA1>MA2”. The expert has an internal engine that interprets these expressions and uses the results.

There are two main types of expressions in mathematics: Logical and Numerical.

Logical expressions return a true or false result and can be a combination of complex logical conditions. For example: “X>12 AND Y-3<8”.

Numerical expressions return a number as the result. For example: (X-2) * (log(2)-6) + Sin(2π) can be written as:

(X-2) * MathExp[3] * (MathLog[2] – 6) + MathSin[2*pi]

ESB supports three kinds of expressions: Logical, Functional, and Conditional/If Expressions.