View source: R/statisticaltests.R
tmodAUC | R Documentation |
Calculate AUC
tmodAUC(
l,
ranks,
modules = NULL,
stat = "AUC",
recalculate.ranks = TRUE,
filter = FALSE,
mset = "all"
)
l |
List of gene names corresponding to rows from the ranks matrix |
ranks |
a matrix with ranks, where columns correspond to samples and rows to genes from the l list |
modules |
optional list of modules for which to make the test |
stat |
Which statistics to generate. Default: AUC |
recalculate.ranks |
Filtering and removing duplicates will also remove ranks, so that they should be recalculated. Use FALSE if you don't want this behavior. If unsure, stay with TRUE |
filter |
Remove gene names which have no module assignments |
mset |
Which module set to use. "LI", "DC" or "all" (default: "all") |
tmodAUC calculates the AUC and U statistics. The main purpose of this function is the use in randomization tests. While tmodCERNOtest and tmodUtest both calculate, for each module, the enrichment in a single sorted list of genes, tmodAUC takes any number of such sorted lists. Or, actually, sortings – vectors with ranks of the genes in each replicate.
Note that the input for this function is different from tmodUtest and related functions: the ordering of l and the matrix ranks does not matter, as long as the matrix ranks contains the actual rankings. Each column in the ranks matrix is treated as a separate sample.
Also, the 'nodups' parameter which is available (and TRUE by default) for other tests cannot be used here. This means that the AUCs calculated here might be slightly different from the AUCs calculated with default parameters in tests such as the [tmodCERNOtest()]. Use 'nodups=FALSE' with [tmodCERNOtest()] to obtain identical results as with 'tmodAUC'.
A matrix with the same number of columns as "ranks" and as many rows as there were modules to be tested.
tmod-package
data(tmod)
l <- tmod_ids(tmod)
ranks <- 1:length(l)
res <- tmodAUC(l, ranks)
head(res)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.