R/compute_holm.R

Defines functions compute_holm

compute_holm <- function(statistic = NULL,pvalue){
  n <- length(pvalue)
  i <- seq_len(n)
  o <- order(pvalue)
  ro <- order(o)
  pvalue <- pmin(1, cummax((n - i + 1L) * pvalue[o]))[ro]
  out=list(main = cbind(statistic = statistic,pvalue = pvalue))
  return(out)

}
jaromilfrossard/permuco documentation built on July 2, 2022, 10:34 p.m.