Learn R Programming

mdgsa (version 1.4.2)

annotMat2list: Convert an annotation matrix into an annotation list.

Description

Converts an annotation matrix to an annotation list. The annotation matrix should have 2 columns, the first one with the gene ids; the second one with the annotation ids.

Usage

annotMat2list(mat)

Arguments

mat
annotation matrix; gene IDs in the first column; block IDs in the second column.

Value

  • An annotation list: elements of the list are vectors of genes; names of the list are Gene Set ids.

Details

Each element of the annotation list represents a functional block; it is a character vector containing the gene ids annotated under the function. The names of the list are the annotation ids.

See Also

annotList2mat, revList, split

Examples

Run this code
mat <- cbind (c("gen1", "gen2", "gen3"), c("Block1", "Block1", "Block2"))
annotMat2list (mat)

Run the code above in your browser using DataLab