adjustPVals | R Documentation |
Wraps around the R base implementation of p.adjust, as well as the methods used in the fdr tool package.
adjustPVals(pVals, adjust = "none", plotFdr = FALSE, verbose = FALSE)
pVals |
Numeric vector of p-values to adjust. |
adjust |
Allows for resulting p-values to be corrected for multiple hypothesis tests. Optional and some non-default choices require the "fdrtool" package. Default = "none", which means that no p-value adjustment is performed. Other options include methods in ?p.adjust (i.e., "holm", "hochberg", "hommel", "bonferroni", "BH", "BY", "fdr"), and methods in ?fdrtool (i.e., "fndr", "pct0", "locfdr"). |
plotFdr |
Allows for plotting of fdrtool p-value adjustment result, if this is chosen. Requires fdrtool package. Default = FALSE. |
verbose |
If TRUE, the function prints out the general method used for multiple correction analysis. Default = FALSE. |
A numeric vector of p-values that have been adjusted according to the specified method.
pvals = runif(100, 0, 1)
adj_pvals_bh = adjustPVals(pvals, adjust = "BH")
adj_pvals_hommel = adjustPVals(pvals, adjust = "hommel")
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.