• mean(A, B, C, ...)—Returns the arithmetic mean, or average, of A, B, C, ..., by summing all elements in the arguments and dividing by the total number of elements.
The arithmetic mean for N number of elements is defined as follows:
The arithmetic mean for an m x n array is defined as follows:
• gmean(A, B, C, ...)—Returns the geometric mean of A, B, C, ....
The geometric mean for N number of elements is defined as follows:
The geometric mean for an m x n array is defined as follows:
The geometric mean is useful for calculating growth rates.
• hmean(A, B, C, ...)—Returns the harmonic mean of A, B, C, ....
The harmonic mean for N number of elements is defined as follows:
The harmonic mean for an m x n array is defined as follows:
The harmonic mean is the reciprocal of the arithmetic mean of the reciprocals.
Arguments
• A, B, C, ... are scalars or m x n arrays.
• Function mean accepts complex and negative values, while gmean and hmean accept only positive real numbers.
Additional Information
The values returned by the three functions have this relationship: