Rdocumentation
powered by
Learn R Programming
robCompositions (version 2.0.0)
gm: geometric mean
Description
This function calculates the geometric mean.
Usage
gm(x)
Arguments
x
A numeric vector.
Value
The geometric mean.
Details
Calculates the geometric mean of all positive entries of a vector.
Examples
Run this code
gm(runif(
100
))
Run the code above in your browser using
DataLab