average()

The average() function returns the average value from a set of values and returns a time-series array.

Syntax

average(value1, value2, [value3]…)

Argument Description
value1

(required)

The first number you want to average.

 

The value arguments can be constants (i.e., hard-coded values or attribute references) and/or references to metrics.

value2

(required)

The second number for which you want to retrieve the average.
value3…

(optional)

The additional numbers for which you want to retrieve the average.

Where Available

  • Metric expression

Examples

Where Example(s)
Metric expression

 

 

average(OPEX__m.actual__d, CAPEX__m.actual__d, Other_Expense__m.actual__d)

average(10, Employee_headcount__c)

Note: in the example above, if the Employee_headcount__c is empty, it would be ignored in the average() and the function would return 10 as the result.

 

Updated on February 7, 2023

Related Articles