R/cv.r

Defines functions cv

Documented in cv

#' Calculate the coefficient of variation
#'
#' @param x A numeric vector
#'
#' @examples 
#' cv(rnorm(20))
#'
#' @export

cv <- function(x){
  sd(x)/abs(mean(x))
}
seananderson/ecofolio documentation built on May 29, 2019, 4:25 p.m.