powered by
The geometric mean is computed as: \(\exp(\bar{log(x)})\), with:
log: natural logarithm
\(\bar{log(x)}\): arithmetic mean of log(x)
geomMean(x, na.rm = FALSE)
Numeric vector of length 1 with geometric mean.
Numeric vector.
Logical, should NA value(s) be removed (FALSE by default)?
Laure Cougnaud
Other stats utility functions: cv(), geomCV(), geomSD(), geomSE(), se()
cv()
geomCV()
geomSD()
geomSE()
se()
# geometric mean of a big sample from log normal distribution # tends to the mean of the distribution: geomMean(rlnorm(n = 1000, meanlog = 0, sdlog = 1))
Run the code above in your browser using DataLab