CALCULATEN

Metadata Instruction: Perform a calculation with a floating point output rounded off to 2 decimal places or type cast a string into a floating point output rounded off to 2 decimal places.
Edited By : Sobhit Sharma

Use Cases - When to use this command

Description

CALCULATEN evaluates a mathematical expression and stores the floating point output of the expression in another variable. If the output of the expression is a Float (a number with decimal places) with more than two decimal places, then output will be rounded off to two decimal places.

Guidelines for Usage:

How to use this command

CALCULATEN command is for node level operations. It can be used in any node as an instruction, except for the root node. It should not be used on the Arrows.

Let's take an example: CALCULATEN $output_variable "25.251 + 45.12"
Here, "$output_variable" is where the result of the expression "25.251 + 45.12" will be stored.
If you had a tree variable "$x1" which was previously initialized to 45.12, the above expression could have also been "25.251 + $x1"

Examples

Simulated Metadata Editor
processing icon
Analytics API Call Body
Analytics API Response Body