pathview R package not working
2
2
Entering edit mode
6.2 years ago

Hi!

I cannot make any useful plots in pathviews. Where am I going wrong?

library(pathview)
a= c( -2,4)
names(a) =c('MDM2', 'TP53')
pathview(gene.data = a, pathway.id = "04115", species = "hsa")

there is no highlighting of either p53 or mdm2 in the resulting fig.

pathview R • 3.2k views
ADD COMMENT
1
Entering edit mode

I think the answers is on the warnings you get:

Warning: None of the genes or compounds mapped to the pathway!
Argument gene.idtype or cpd.idtype may be wrong.
ADD REPLY
6
Entering edit mode
6.2 years ago
Benn 8.4k

You can't use the gene names (symbols), but have to use ENTREZ gene IDs.

library(pathview)
a= c( -2,4)
names(a) =c("4193", "7157")
pathview(gene.data = a, pathway.id = "04115", species = "hsa")

To get these entrez IDs you can use org.Hs.eg.db in R.

library(org.Hs.eg.db)
symbols = c("MDM2","TP53") 
names(a) <- mget(symbols, revmap(org.Hs.egSYMBOL),ifnotfound=NA)
ADD COMMENT
1
Entering edit mode

Thank you indeed very much @b.nota

ADD REPLY
0
Entering edit mode
5.5 years ago

Thank you.....FOR KEGG RESULTS HIGHLIGHTED THE TARGETED GENES

ADD COMMENT

Login before adding your answer.

Traffic: 1693 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