Syntax
AVERAGE(A1 [; ByEveryN])
Arguments
A1 must be an array.
ByEveryN is an optional argument: an integer constant, greater than or equal to 1.
Result
Returns a scalar value, which is the average value of the elements in the array A1.
If ByEveryN is supplied, then the function calculates the average value of every N successive elements and the result is an array.
Description
Calculates the average of the elements in the input array, or the average of every N successive elements in the input array.
Example 1:
Expression: AVERAGE( arg1 )
arg1 | 11 | 7 | 3 | 5 | 6 | 1 |
Result: 5.5
Example 2: (average by every 2 elements)
Expression: AVERAGE( arg1; 2 )
arg1 | 11 | 7 | 3 | 5 | 6 | 1 |
result | 9 | 4 | 3.5 |
Related Examples
Windows Forms: Data Manipulation\Functions\Average, Min, Max