Want to share your content on R-bloggers? click here if you have a blog, or here if you don't.

This is a feature request from clusterProfiler user. It’s similar to what I implemented in clusterProfiler for comparing biological themes. For comparing different enrichment results, the x-axis represent different gene clusters while for a single enrichment result, the x-axis can be gene count or gene ratio. This is actually similar to traditional barplot, with dot position as bar height and dot color as bar color. But dotplot can represent one more feature nicely by dot size and it can be a good alternative to barplot.

?View Code RSPLUS
 1 2 3 4  library(DOSE) deg = names(geneList)[abs(geneList) > 1] do = enrichDO(deg) dotplot(do, showCategory=20)

We can set the x-axis to use gene count and dot color by one of ‘pvalue’, ‘p.adjust’ or ‘qvalue’.

?View Code RSPLUS
 1  dotplot(do, x="count", showCategory=20, colorBy="qvalue")

The dotplot function is also available in clusterProfiler and ReactomePA.