This is a test version of Biostars. For the public version, visit https://www.biostars.org.
No result in enrichGO

Hi, I am new to clusterProfiler and following the R documentation.

In the website instruction for enrichplot, here is some demo for enrichGO:

library(clusterProfiler)
data(geneList, package="DOSE")
de <- names(geneList)[abs(geneList) > 2]
ego <- enrichGO(de, OrgDb = "org.Hs.eg.db", ont="BP", readable=TRUE)
library(enrichplot)
goplot(ego)

And I just use this but get no results. Here is my code:

library(clusterProfiler)
library(org.Hs.eg.db)
library(DOSE)
data(geneList)
de <- names(geneList)[abs(geneList) > 2]
ego <- enrichGO(de, OrgDb = "org.Hs.eg.db", ont="BP", readable=TRUE)
head(summary(ego))

and I get:

> head(summary(ego))
[1] ID          Description GeneRatio   BgRatio     pvalue      p.adjust    qvalue      geneID      Count      
<0 rows> (or 0-length row.names)
Warning message:
In summary(ego) :
  summary method to convert the object to data.frame is deprecated, please use as.data.frame instead.

So, what's wrong about my performance? Could anyone give me a hint.

r clusterprofiler enrichgo

Hi, Just type the following head(summary(as.data.frame(ego))).It should work

No, this code just makes a more decent summary, but the result is still nothing.

2 answers

Hey!

Could you please show me with your contents of 'de', the input of your enrichGo command.

Because for my case, I will try to change my gene ID from 'ensembl_ID' to 'entrezid' to get more mapping results.

Since you got nothing mapping results, I guess there is something wrong in your input genes.

#Group_4 enriched Go terms

group4_top100_gene<- as.character((markergenes$Ensembl_ID)[9920:10019])

ID <- bitr(group4_top100_gene, fromType="ENSEMBL", toType="ENTREZID", OrgDb="org.Dr.eg.db")

head(ID)

ego <- enrichGO(gene = as.vector(ID$ENTREZID),
                OrgDb=org.Dr.eg.db,
                ont = "BP",
                minGSSize = 1,
                pvalueCutoff = 0.05,
                qvalueCutoff = 1,
                readable = TRUE)
head(summary(ego))

dim(ego)

result <- simplify(ego, cutoff=0.7, by="p.adjust", select_fun=min)

barplot(result, showCategory=10,title="GO terms enriched in group_4")

dotplot(result,showCategory=15,title="GO terms enriched in group_4")
dim(result)

Bests Shizheng

Sure, here is the contents:

> de
  [1] "4312"   "8318"   "10874"  "55143"  "55388"  "991"    "6280"   "2305"   "9493"   "1062"   "3868"  
 [12] "4605"   "9833"   "9133"   "6279"   "10403"  "8685"   "597"    "7153"   "23397"  "6278"   "79733" 
 [23] "259266" "1381"   "3627"   "27074"  "6241"   "55165"  "9787"   "7368"   "11065"  "55355"  "9582"  
 [34] "220134" "55872"  "51203"  "3669"   "83461"  "22974"  "10460"  "10563"  "4751"   "6373"   "8140"  
 [45] "79019"  "820"    "10635"  "1844"   "4283"   "27299"  "55839"  "27338"  "890"    "9415"   "983"   
 [56] "54821"  "10232"  "4085"   "6362"   "9837"   "5080"   "7850"   "81930"  "5918"   "81620"  "332"   
 [67] "55765"  "79605"  "3832"   "6286"   "5163"   "2146"   "3002"   "50852"  "7272"   "2568"   "64151" 
 [78] "51806"  "366"    "2842"   "9212"   "140578" "51659"  "8715"   "4902"   "8208"   "1111"   "9319"  
 [89] "9055"   "3833"   "146909" "23475"  "4321"   "11182"  "10112"  "3902"   "3620"   "3887"   "51514" 
[100] "6790"   "4521"   "891"    "57110"  "8544"   "1448"   "24137"  "6355"   "10578"  "4174"   "9232"  
[111] "643314" "1307"   "776"    "4129"   "9370"   "196740" "25924"  "8857"   "1602"   "51161"  "3708"  
[122] "23090"  "10742"  "51760"  "9122"   "10699"  "8416"   "60598"  "79148"  "64799"  "4629"   "1556"  
[133] "55096"  "26289"  "6038"   "771"    "51313"  "23704"  "3117"   "80129"  "23158"  "125"    "4958"  
[144] "4857"   "1311"   "5105"   "5174"   "730"    "2018"   "81563"  "2532"   "1308"   "4250"   "23362" 
[155] "2167"   "51705"  "2593"   "652"    "80736"  "4036"   "57502"  "5507"   "56521"  "22885"  "4137"  
[166] "8483"   "8839"   "2066"   "4693"   "4148"   "79083"  "1101"   "3158"   "3169"   "5346"   "1408"  
[177] "9547"   "2922"   "11283"  "64499"  "54829"  "1524"   "10234"  "1580"   "10647"  "25893"  "24141" 
[188] "10351"  "2330"   "5304"   "79846"  "8614"   "2625"   "7021"   "7802"   "79689"  "11122"  "55351" 
[199] "9"      "4239"   "5241"   "10551"  "10974"  "79838"  "79901"  "57758"  "4969"

There code is from the website instruction and I think the default process uses entrez_id.

Hey Sugus,

I just tried your codes and it works well.

library(clusterProfiler)
library(org.Hs.eg.db)
de<-c("4312","8318","10874","55143","55388","991")
ego <- enrichGO(de, OrgDb = "org.Hs.eg.db", ont="BP", readable=TRUE)
head(summary(ego))

    ID                          Description GeneRatio   BgRatio       pvalue   p.adjust      qvalue      geneID Count
GO:0006270 GO:0006270           DNA replication initiation       2/6  42/17381 8.498316e-05 0.01453212 0.006440829 CDC45/MCM10     2
GO:0007062 GO:0007062            sister chromatid cohesion       2/6 133/17381 8.543746e-04 0.04335978 0.019217629 CDCA8/CDC20     2
GO:0000070 GO:0000070 mitotic sister chromatid segregation       2/6 142/17381 9.730351e-04 0.04335978 0.019217629 CDCA8/CDC20     2
GO:0006261 GO:0006261        DNA-dependent DNA replication       2/6 145/17381 1.014264e-03 0.04335978 0.019217629 CDC45/MCM10     2
GO:0000819 GO:0000819         sister chromatid segregation       2/6 230/17381 2.525189e-03 0.04962063 0.021992521 CDCA8/CDC20     2
GO:0140014 GO:0140014             mitotic nuclear division       2/6 253/17381 3.045861e-03 0.04962063 0.021992521 CDCA8/CDC20     2

    Warning message:
In summary(ego) :
  summary method to convert the object to data.frame is deprecated, please use as.data.frame instead.

Yes, it works today. So weird.....

Dear all,

I'm trying to run groupGO, but its return "no count, noGeneRatio and no geneID but just a list as shown below:

"ID" "Description" "Count" "GeneRatio" "geneID"
"GO:0005886" "GO:0005886" "plasma membrane" 0 "0/0" ""
"GO:0005628" "GO:0005628" "prospore membrane" 0 "0/0" ""
"GO:0005789" "GO:0005789" "endoplasmic reticulum membrane" 0 "0/0" ""
"GO:0019867" "GO:0019867" "outer membrane" 0 "0/0" ""
"GO:0031090" "GO:0031090" "organelle membrane" 0 "0/0" ""
"GO:0034357" "GO:0034357" "photosynthetic membrane" 0 "0/0" ""
"GO:0036362" "GO:0036362" "ascus membrane" 0 "0/0" ""

and return "No gene can be mapped" when I ran enrichGO after this.

Can anyone please assist? let say I have a gene list "Erf","Cdh22","Arhgap8","Rab11fip4","Mn1","Grb10","Ehbp1" for rat?

Appreciate that.

Best wishes, WF

I had this same problem! I ran enrichGO() and it returned "0 rows (or 0-length row.names)".

Turns out the problem was that none of my results met the implicit p-value and q-value cutoffs. Try specifying:

qvalueCutoff = 1, pvalueCutoff = 1

See if you get results this way.

Log in to answer this question.