catDB-class | R Documentation |
"catDB"
Container for storing mappings of genes to annotation categories
such as gene ontologies (GO), pathways or conserved sequence domains.
The catmap
slot stores a list
of data.frames
providing the direct
assignments of genes to annotation categories (e.g. gene-to-GO mappings);
catlist
is a list
of lists
of all direct and indirect associations to
the annotation categories (e.g. genes mapped to a pathway); and idconv
allows to store a lookup-table for converting identifiers (e.g. array feature
ids to gene ids).
Objects can be created by calls of the form new("catDB", ...)
.
catmap
:Object of class "list"
list
of data.frames
catlist
:Object of class "list"
list
of lists
idconv
:Object of class "ANY"
list
of data.frames
signature(x = "catDB")
: extracts data from catlist
slot
signature(x = "catDB")
: extracts data from catmap
slot
signature(from = "list", to = "catDB")
: as(list, "catDB")
signature(x = "catDB")
: extracts data from idconv
slot
signature(x = "catDB")
: extracts slot names
signature(object = "catDB")
: summary view of catDB
objects
Thomas Girke
makeCATdb
, GOHyperGAll
, GOHyperGAll_Subset
, GOHyperGAll_Simplify
, GOCluster_Report
, goBarplot
showClass("catDB")
## Not run:
## Obtain annotations from BioMart
library("biomaRt")
listMarts() # To choose BioMart database
listMarts(host = "plants.ensembl.org")
m <- useMart("plants_mart", host = "plants.ensembl.org")
listDatasets(m)
m <- useMart("plants_mart", dataset = "athaliana_eg_gene", host = "plants.ensembl.org")
listAttributes(m) # Choose data types you want to download
go <- getBM(attributes = c("go_id", "tair_locus", "namespace_1003"), mart = m)
go <- go[go[, 3] != "", ]
go[, 3] <- as.character(go[, 3])
go[go[, 3] == "molecular_function", 3] <- "F"
go[go[, 3] == "biological_process", 3] <- "P"
go[go[, 3] == "cellular_component", 3] <- "C"
go[1:4, ]
dir.create("./data/GO", recursive = TRUE)
write.table(go, "data/GO/GOannotationsBiomart_mod.txt", quote = FALSE, row.names = FALSE,
col.names = FALSE, sep = "\t")
## Create catDB instance (takes a while but needs to be done only once)
catdb <- makeCATdb(myfile = "data/GO/GOannotationsBiomart_mod.txt", lib = NULL, org = "",
colno = c(1, 2, 3), idconv = NULL)
catdb
save(catdb, file = "data/GO/catdb.RData")
load("data/GO/catdb.RData")
## End(Not run)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.