Many of the ADL blocks allow you to define formulas to calculate output values. The Formula Builder contains a canvas onto which you can drag-and-drop components of an equation, including:
Example Define a formula that compares a fill quantity with the quantity available at the Best Ask.
Note Based on the block type, some Formula Builders will provide or restrict components that do not pertain to the block functionality.
The Formula Builder includes tiles that allow you to add values that update dynamically as the algo runs.
: Lets you to enter a specific number.
: Lets you reference the output of any other block in the algorithm.
: Lets you extract any of the following information embedded within a discrete event message.
: (Alert block only) Lets you add customized text to a message string.
The following ADL blocks allow you to create custom formulas.
Trading blocks
Discrete blocks
Misc blocks
To create a formula:
From an ADL block, open the Formula Builder.
Drag a field tile onto the canvas.
If necessary, select a value for the field and click OK.
The field updates with the selected value.
Drag another field tile onto the canvas, in this case the + operator.
Notice in this case, the canvas turns red after adding the operator. The red canvas indicates that the formula currently on the canvas is not valid.
Continue adding field tiles until the formula is complete. In this case, you add a Block Value field and select the Price Incr block to add one tick to the fill price.