gm_mean: Geometric mean

Description Usage Arguments Examples

Description

Generic function calculates the geometric mean

Usage

1
gm_mean(x, na.rm = TRUE, trim = 0, ...)

Arguments

x

numeric vector of values

na.rm

a logical value indicating weather NA values should be stripped before the computation occurs. Defaults to FALSE

trim

the fraction (o to 0.5) of observations to be trimmed from each end of x before the geometric mean is computed. Values of trim outside that range are taken as the nearest endpoint.

...

further arguments passed to or from other methods.

Examples

1
2
x <- rlnorm(50, log(100), log(2))
xm <- gm_mean(x)

mps9506/watertools documentation built on May 20, 2019, 3:32 p.m.