Hi! I am trying to perform hypergeometric test to find enriched GO terms among the genes that differ significantly between two clusters. However, I have a problem when I try to get a summary of the hypergeometric test from GOstats package - I get the following error:
Error in initialize(value, ...) : argument "go_id" is missing, with no default
For the annotation I use hgu133plus2.db package (my microarrays are Affymetrix HG U133 + PM) and the way I get to the universe and selected genes' Entrez ID is as follows:
x <- hgu133plus2ENTREZID mapped_probes <- mappedkeys(x) universe <- unique(unlist(as.list(x[mapped_probes]))) sig_probes <- rownames(res)[which(res[,3] != 0)] # res is a result of decideTests from limma package so in this line I am picking all the significant genes from the comparison of interest to me sig_probes <- sub(x = sig_probes, pattern = "_PM_", replacement = "_") # I am changing IDs to match them with IDs in hgu133plus2.db package significant <- unlist(as.list(x[sig_probes])) significant <- unique(significant[!is.na(significant)]) # going to the hypergeometric test params <- new('GOHyperGParams', geneIds=significant, universeGeneIds=universe, ontology='BP', pvalueCutoff=0.001, conditional=F, testDirection='over', annotation="hgu133plus2.db") hgOver <- hyperGTest(params) result <- summary(hgOver)
I would expect this is some problem with an annotation? Any help regarding what I can be doing wrong will be appreciated.