ClusterProfiler dotplot method does not include all input groups.
0
0
Entering edit mode
3.7 years ago
markm014 ▴ 40

I am using the clusterProfiler methods enrichGO and dotplot to do some downstream differential expression analysis. I invoke enrichGO with the following call:

formula_res = compareCluster(`EntrezGene ID~Direction+Treatment, data=filtered_data, fun="enrichGO", OrgDb="org.Hs.eg.db", ont="BP", qvalueCutoff= 0.2, readable=TRUE)

where filtered_data is a dataframe with the follwoing columns:

Gene, EntrezGene ID, Gene Stable ID, Name, Treatment, Direction

Then, plot via the call to dotplot:

p = dotplot(formula_res, showCategory=10, title="test", font.size=9, includeAll = TRUE)

I am surprised that if I have in my data frame 8 unique combinations of treatment and direction (Ex: four different treatments with both up and down regulated genes for each) my dotplot often outputs less groups. For instance, I often get a plot with six groups shown despite having eight "input groups" (as defined by unique combination of direction + treatment).

I have read the documentation and tried setting showCategory to NULL instead of 10, which the documentation says should force a return of all groups, but still not all treatments are included. Am I missing something obvious on this one? I want to verify my results are not erroneous.

clusterProfiler R dotplot differential expression • 1.4k views
ADD COMMENT
0
Entering edit mode

If it doesn't find any enriched terms for a group that group probably doesn't get added to the result. Try running enrichGO on some of the groups that didn't appear in your results.

ADD REPLY
0
Entering edit mode

Thank you for taking the time to answer. The thing is, when I run the enrichGo function on each of the 8 input groups separately with the same parameters, they all 8 have significant GO terms. Sorry, I should have included this above!

ADD REPLY

Login before adding your answer.

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