GeometricMean {tricolore} | R Documentation |
Geometric Mean
Description
Calculate the geometric mean for a numeric vector.
Usage
GeometricMean(x, na.rm = TRUE, zero.rm = TRUE)
Arguments
x |
Numeric vector. |
na.rm |
Should NAs be removed? (default=TRUE) |
zero.rm |
Should zeros be removed? (default=TRUE) |
Value
The geometric mean as numeric scalar.
Examples
# NOTE: only intended for internal use and not part of the API
tricolore:::GeometricMean(0:100)
tricolore:::GeometricMean(0:100, zero.rm = FALSE)
[Package tricolore version 1.2.4 Index]