How get genename by tximport
1
0
Entering edit mode
lkianmehr • 0
@lkianmehr-16873
Last seen 2.9 years ago
Iran

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 • 2.4k views
ADD COMMENT
2
Entering edit mode
@mikelove
Last seen 22 hours ago
United States

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 COMMENT

Login before adding your answer.

Traffic: 450 users visited in the last hour
Help About
FAQ
Access RSS
API
Stats

Use of this site constitutes acceptance of our User Agreement and Privacy Policy.

Powered by the version 2.3.6