gmean: Geometric mean of a vector

View source: R/RcppExports.R

gmeanR Documentation

Geometric mean of a vector

Description

Compute geometric mean of a vector using exp(mean(log(.x))) format

Usage

gmean(vec)

Arguments

vec

A vector of values with length n

Value

A numeric value of the geometric mean of the vector vec

Examples

ex <- abs(rnorm(10))
gmean(ex)

qpmnguyen/teaR documentation built on April 4, 2022, 7:26 p.m.