By using the online tool David (https://david.ncifcrf.gov) for GO enrichment analysis and the R package GOplot (https://wencke.github.io) I was able to associate a z-score to my gene ontology results. I run the analysis for 3 different conditions (Cond1, Cond2, Cond3) and selected the most interesting GO terms. Now I have a data frame like this:
GO ID term Cond1_PADJ Cond1_Zscore Cond2_PADJ Cond2_Zscore Cond3_PADJ Cond3_Zscore BP GO:0030198 extracellular matrix organization 3.89101E-05 -2.683281573 5.06412E-12 3.713069518 2.14344E-07 -5.099019514 BP GO:0030154 cell differentiation 0.000553172 -0.239045722 0.002762293 0.784464541 4.07139E-06 -8.373983252
At this point I would like to generate a dot plot pretty similar to the one discussed here (A: Dotplot for filtered pathways result) using ggplot2, but with some adjustments: 1) The size of the dots should be relative to the -log of the PADJ (instead of the Gene Ratio) 2) The colour of the dots should be relative to the Z-score (instead of the p-value) 3) I would like to separate the lanes of my samples like this (relevel the clusterProfiler object)
I know there are some tools out there like Cluster profiler, Pathfindr, etc that can generate this graph, but I just need to plot my results.
Thank you : )