Learn R Programming

tmod (version 0.19)

tmodAUC: Calculate AUC

Description

Calculate AUC

Usage

tmodAUC(l, ranks, modules = NULL, stat = "AUC", remove.dups = TRUE,
  recalculate.ranks = TRUE, filter = FALSE, mset = "LI")

Arguments

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
remove.dups
Remove duplicate gene names in l and corresponding rows from ranks
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: LI)

Value

  • A matrix with the same number of columns as "ranks" and as many rows as there were modules to be tested.

Details

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.

See Also

tmod-package

Examples

Run this code
data(tmod)
l <- tmod$GENES$ID
ranks <- 1:length(l)
res <- tmodAUC(l, ranks)
head(res)

Run the code above in your browser using DataLab