mapGeneNames | R Documentation |
Mapping human and mouse genes to HGNC or MGI gene symbols or across species.
downloadEnsemblData(host="www.ensembl.org")
mapGeneNames(maps, genes, in.org=c("Hsap","Mmus"), in.name=c("symbol","ensg"), out.org=c("Hsap","Mmus"), out.name=c("symbol","ensg"))
host |
URL to download ensembl data from (e.g. archive vs current). |
maps |
output from downloadEnsemblData. |
genes |
vector of gene IDs. |
in.org |
organism of input genes. |
in.name |
input gene ID type. |
out.org |
desired organism for output genes. |
out.name |
desired ID type for output. |
downloadEnsemblData
: Downloads gene ids and orthologs for all protein-coding genes from ensembl biomart.
mapGeneNames
: Converts genes from one type to another or to orthologs in the other species.
The input SingleCellExperiment object with the regressed expression saved to the 'norm_exprs' slot.
maps <- downloadEnsemblData();
# Convert Whitfield CC table for use in mouse
MGeneSets$Whitfield <- HGeneSets$Whitfield
MGeneSets$Whitfield$Gene <- mapGeneNames(maps, as.character(MGeneSets$Whitfield$Gene), in.org="Hsap", in.name="symbol", out.org="Mmus", out.name="symbol")
MGeneSets$Whitfield <- MGeneSets$Whitfield[MGeneSets$Whitfield$Gene != "",] #remove genes without orthologs.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.