Hello, I am trying to make volcano plot of the multiple microarray results data in the single plot itself and annotating them by different colors. I know how to generate the Volcano plot for single result, but the same logic I can't apply for multiple results. I googled it but there also i didn't get any satisfactory results
Following is the example dataset,
This will result in a Volcano plot graphing Fold change versus -log10(FDR), with each point colored by whether it's a significant difference (defined by both absolute value of log2FC and significance) and with a shape corresponding to the sample.
That being said, I think ATpoint makes a good suggestion with multiple different plots on the same page, I'd worry about overplotting.
Simply make the volcano with the first dataset using the standard plot command and then use points specifying a different color to add extra datapoints to the existing plot corresponding to the other studies. Later use legend to make a proper legend matching colors with the study name.
plot(study1$logFC, -log10(study1$pvalue), col="black")
points(study2$logFC, -log10(study2$pvalue), col="red")
(and so on...)
Can probably be done with a simple for loop.
Make sure you check the data range for x and y-axis beforehand so that no added points go beyond the limits from the first plot. Still, will probably get a bit messy adding so many data points. Maybe independent plots on the same page par(mfrow=c(2,2)) to get four plots on one page might be better.
Yes this can be a good method, Thank you @shawn.w.foley