annotateFromBiomart: Annotate your Expression Set with biomaRt

View source: R/annotateFromBiomart.R

annotateFromBiomartR Documentation

Annotate your Expression Set with biomaRt

Description

Annotate your Expression Set with biomaRt

Usage

annotateFromBiomart(obj, genes = featureNames(obj),
  filters = "ensembl_gene_id", attributes = c("ensembl_gene_id",
  "hgnc_symbol", "chromosome_name", "start_position", "end_position"),
  biomart = "ensembl", dataset = "hsapiens_gene_ensembl", ...)

Arguments

obj

ExpressionSet object.

genes

Genes or rownames of the ExpressionSet.

filters

getBM filter value, see getBM help file.

attributes

getBM attributes value, see getBM help file.

biomart

BioMart database name you want to connect to. Possible database names can be retrieved with teh function listMarts.

dataset

Dataset you want to use. To see the different datasets available within a biomaRt you can e.g. do: mart = useMart('ensembl'), followed by listDatasets(mart).

...

Values for useMart, see useMart help file.

Value

ExpressionSet object with a fuller featureData.

Examples


data(skin)
# subsetting and changing column name just for a silly example
skin <- skin[1:10,]
colnames(fData(skin)) = paste("names",1:6)
host<-"dec2013.archive.ensembl.org"; biomart<-"ENSEMBL_MART_ENSEMBL";
genes <- sapply(strsplit(rownames(skin),split="\\."),function(i)i[1])
newskin <-annotateFromBiomart(skin,genes=genes,biomar=biomart,host=host)
head(fData(newskin)[,7:11])


QuackenbushLab/yarn documentation built on March 7, 2024, 3:53 p.m.