gm_mean: Geometric mean

Description Usage Arguments Value Examples

View source: R/helper_functions.R

Description

Calculate the geometric mean of a vector of numbers

Usage

1
gm_mean(x, na.rm = TRUE)

Arguments

x

an R numerical object

na.rm

a logical value indicating whether NA values should be stripped before the computation proceeds.

Value

If all values in x are numeric class, a single numeric class value is returned.

Examples

1
2
x <- c(0:10, 50)
gm_mean(x)

MjStansfi/GEKS_package documentation built on May 12, 2021, 8:44 p.m.