Learn R Programming

missMethyl (version 1.6.2)

getMappedEntrezIDs: Get mapped Entrez Gene IDs from CpG probe names

Description

Given a set of CpG probe names and optionally all the CpG sites tested, this function outputs a list containing the mapped Entrez Gene IDs as well as the numbers of probes per gene, and a vector indicating significance.

Usage

getMappedEntrezIDs(sig.cpg, all.cpg = NULL)

Arguments

sig.cpg
character vector of significant CpG sites used for testing gene set enrichment
all.cpg
character vector of all CpG sites tested. Defaults to all CpG sites on the array.

Value

  • A list with the following elements
  • sig.egmapped Entrez Gene IDs for the significant probes
  • universemapped Entrez Gene IDs for all probes on the array, or for all the CpG probes tested.
  • freqtable output with numbers of probes associated with each gene
  • dea vector of ones and zeroes of the same length of universe indicating which genes in the universe are significantly differentially methylated.

Details

This function is used by the gene set testing functions gometh and gsameth. It maps the significant CpG probe names to Entrez Gene IDs, as well as all the CpG sites tested. It also calculated the numbers of probes for gene. Genes associated with each CpG site are obtained from the annotation package IlluminaHumanMethylation450kanno.ilmn12.hg19.

See Also

gometh,gsameth

Examples

Run this code
library(IlluminaHumanMethylation450kanno.ilmn12.hg19)
library(org.Hs.eg.db)
library(limma)
ann <- getAnnotation(IlluminaHumanMethylation450kanno.ilmn12.hg19)

# Randomly select 1000 CpGs to be significantly differentially methylated
sigcpgs <- sample(rownames(ann),1000,replace=FALSE)

# All CpG sites tested
allcpgs <- rownames(ann)

mappedEz <- getMappedEntrezIDs(sigcpgs,allcpgs)
mappedEz$sig.eg[1:10]
mappedEz$universe[1:10]
mappedEz$freq[1:10]
mappedEz$de[1:10]

Run the code above in your browser using DataLab