Question: Using GANPA package in R to do enrichment analysis
gravatar for zjw6291
3.1 years ago by
zjw62910 wrote:

Dear all

I am trying to use the GSE.Test.Main function in the GANPA package in R to do enrichment analysis of my microarray data. I've checked the example in the document and I'm sure that all my data including the gene sets and the expression value are in the exact same format as it suggests in the document. But I'm not sure how to choose the gene network in the algorithm, so I just go with the one in the example. However, an error comes up when I run that function. And I can't figure out what goes wrong.

Here are my codes:

The expSet2 is a list of expression value and the gexp is the input of the expression value as it suggests in the document. The gset it the list of gene sets.

expSet <- read.csv("E:/SIAT/expressiondifference10.9/expression_profile.csv", header = T)
rownames(expSet) <- expSet[,1]
expSet <- expSet[,-1]
expSet2 <- as.matrix(expSet)
attr(expSet2, "dimnames") <- list(rownames(expSet), colnames(expSet))

sampleinfo <- cbind(sampleid = c("a40_s16_1","a40_s48_1","a40_s55_1","a40_s68_1",
  status = c(rep("young",4), rep("old",4)))
rownames(sampleinfo) <- colnames(expSet)
gexp <- list(gExprs = expSet2, samleinfo = sampleinfo)

completepath <- list.files(pattern = "*.txt")
gset <- lapply(setNames(completepath, make.names(gsub("*.txt$","",completepath))),
           function(i) as.character(unlist(read.table(i))))

GSE.Test.Main(gExprs.obj = gexp, gsets = gset, gNET = gNET, 
          check.exprs = F, permN = 100, randN = 30, permFDR.cutoff = 0.1,
          output.label = "gsea", msp.correction = F)

And here is the the error information:

Error in obtainT(gExprs = gExprs.obj, reverse = FALSE, check.exprs = check.exprs,  : 
   obtainT(): status number is not 2!
In addition: Warning message:
In : applied to non-(list or vector) of type 'NULL'

If anyone has any idea about my question, please help me !!!!!!


gene R software error • 1.1k views
ADD COMMENTlink modified 3.1 years ago • written 3.1 years ago by zjw62910

Just at a quick glance, there is a typo here:

gexp <- list(gExprs = expSet2, samleinfo = sampleinfo)

You wrote samleinfo instead of sampleinfo. The function refers to the "pieces" of your expression object by name, so it is trying to find "sampleinfo" and it can not do it because you mis-labelled it. Try to fix this and see if it works.

ADD REPLYlink written 3.1 years ago by Selenocysteine600

Oh this is awkward... Thank you so much!!

ADD REPLYlink written 3.1 years ago by zjw62910
Please log in to add an answer.


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