R/geometric_mean.R

#' Geometric mean
#'
#' Normalize to housekeeping genes
#' @param x numeric
#' @return numeric
#' @export
gm_mean = function(x, na.rm=TRUE){
  exp(sum(log(x[x > 0]), na.rm=na.rm) / length(x))
}
SCIL-leuven/qPCR documentation built on May 31, 2019, 6:39 p.m.