Transformation
Aggregate Functions For Arrays
Overview
This JST allows IAP users to pass in an array of numbers and run a set of mathematical aggregate functions on the items. Users can also use this JST on the aggregated arrays returned by the GroupBy Property pre-built. The aggregate functions supported are:
No. | Function |
---|---|
1 | Sum |
2 | Product |
3 | Maximum |
4 | Minimum |
5 | Range |
6 | Count |
7 | Arithmetic Mean |
8 | Geometric Mean |
9 | Harmonic Mean |
10 | Median |
11 | Mode |
12 | Standard Deviation |
13 | Variance |
The JST expects all the items in the array to be either numbers or parsable number strings (which will be converted to numbers); however, if there is a non-number/non-parsable string item, the item will simply be ignored from all calculations and returned as part of the valuesIgnored
array. Values which are used in calculations will be returned in the valuesUsed
array in their original forms (as strings/numbers) and in the valuesUsed-converted
array in their converted forms (all numbers).
How to Install
To install the pre-built:
- Verify you are running a supported version of the Itential Automation Platform (IAP) as listed above in the Prerequisites section.
- The pre-built can be installed from within
App-Admin_Essential
. Simply search for the name of your desired pre-built and click the install button.