Hi everyone,
I am using Gage to analyse the pathways that are different between 2 conditions. Everything works fine but when I arrived to the pathview part, I keep getting the same error:
select()' returned 1:1 mapping between keys and columns
Info: Working in directory
Info: Writing image file hsa03010.pathview.multi.png
Show Traceback
Rerun with Debug
Error in array(col.rgb[, i], dim(node.rgb)[3:1]) :
negative length vectors are not allowed
I don't know what is the problem since the gage runs perfectly fine. It returns the up and down regulated pathways... Could you please help me to debug it?
Here is my code:
ref.idx=1:44 #controls
samp.idx.1=45:73 #pd
cnts_ent.kegg.p=gage(PD.genes.GAGE,gsets=kegg.gs,ref=ref.idx,samp=samp.idx.1,compare = "as.group")
diff.expr=PD.genes.GAGE[,samp.idx.1] - rowMeans(PD.genes.GAGE[,ref.idx])
sel=cnts_ent.kegg.p$greater[,"q.val"]< 0.05 &
!is.na(cnts_ent.kegg.p$greater[,"q.val"])
path.ids=rownames(cnts_ent.kegg.p$greater)[sel]
path.ids2=substr(path.ids,1,8)
library(pathview)
pv.out.list=sapply(path.ids2[1:length(path.ids2)], function(pid) pathview(gene.data = as.matrix(diff.expr), pathway.id = pid, species = "hsa", gene.idtype="kegg"))
P.s: the version of my pathview package is 1.2 ...
Thank you in advance!
Dear Weijun,
My versions are both updated to the ones you suggested... This is not the problem in my case...