Question: How get genename by tximport
0
gravatar for lkianmehr
6 months ago by
lkianmehr0
lkianmehr0 wrote:

Hello,

I am trying to get gene name as well as geneid and tx id, but I do not know how. tx2gene.gencode.M19 GRCm38.p6.csv is list of GENEID and TXID. the list of gene and transcript name is in another file like tx2gene.csv

could you please guide how can I do it?

tx2gene <- read_csv(file.path(dir, "tx2gene.gencode.M19 GRCm38.p6.csv"))

txi <- tximport(files, type = "salmon", tx2gene = tx2gene)

with theses commands I jut get geneid and TXid, I'd like to have genesymbol or genename. should I kept genename columns is quant.sf file to do that?

 

thanks

 

tximport genename • 192 views
ADD COMMENTlink modified 6 months ago by Michael Love23k • written 6 months ago by lkianmehr0
Answer: How get genename by tximport
1
gravatar for Michael Love
6 months ago by
Michael Love23k
United States
Michael Love23k wrote:

tximport doesn't provide functionality for adding gene symbols by itself.

I do not recommend to have gene symbols or gene names as the row names of the dataset, but instead add these on as metadata columns. The Ensembl IDs are much better as row names of the dataset.

One way to get the gene names is using the annotation packages. And here is some more information on how to use the annotation packages:

http://bioconductor.org/packages/release/workflows/vignettes/annotation/inst/doc/Annotation_Resources.html#orgdb-objects

> library(org.Mm.eg.db)
> db <- org.Mm.eg.db
> columns(db)
 [1] "ACCNUM"       "ALIAS"        "ENSEMBL"      "ENSEMBLPROT"  "ENSEMBLTRANS" "ENTREZID"
 [7] "ENZYME"       "EVIDENCE"     "EVIDENCEALL"  "GENENAME"     "GO"           "GOALL"
[13] "IPI"          "MGI"          "ONTOLOGY"     "ONTOLOGYALL"  "PATH"         "PFAM"
[19] "PMID"         "PROSITE"      "REFSEQ"       "SYMBOL"       "UNIGENE"      "UNIPROT"

> mapIds(db, keys="ENSMUSG00000030359", column="SYMBOL", keytype="ENSEMBL")
'select()' returned 1:1 mapping between keys and columns
ENSMUSG00000030359
             "Pzp"
ADD COMMENTlink written 6 months ago by Michael Love23k
Please log in to add an answer.

Help
Access

Use of this site constitutes acceptance of our User Agreement and Privacy Policy.
Powered by Biostar version 16.09
Traffic: 155 users visited in the last hour