Volcano plot in DEseq2
2
2
Entering edit mode
John ▴ 30
@john-9676
Last seen 5.9 years ago

Hi,

I just took the following code snippet from EdgeR tutorial to have volcano plot in my DEseq2 analysis workflow. I couldn't see interesting results. Is it because my lfc and pval threshold choice? Could someone please help?

 

tab = data.frame(logFC = res$log2FoldChange, negLogPval = -log10(res$pvalue))
head(tab)
par(mar = c(5, 4, 4, 4))
plot(tab, pch = 16, cex = 0.6, xlab = expression(log[2]~fold~change), ylab = expression(-log[10]~pvalue))
lfc = 2
pval = 0.01
signGenes = (abs(tab$logFC) > lfc & tab$negLogPval > -log10(pval))
points(tab[signGenes, ], pch = 16, cex = 0.8, col = "red") 
abline(h = -log10(pval), col = "green3", lty = 2) 
abline(v = c(-lfc, lfc), col = "blue", lty = 2) 
mtext(paste("pval =", pval), side = 4, at = -log10(pval), cex = 0.8, line = 0.5, las = 1) 
mtext(c(paste("-", lfc, "fold"), paste("+", lfc, "fold")), side = 3, at = c(-lfc, lfc), cex = 0.8, line = 0.5)

 

Thanks,

J.

deseq2 • 7.8k views
ADD COMMENT
1
Entering edit mode
@mikelove
Last seen 11 hours ago
United States
The code here looks correct for building a plot from a results object.
ADD COMMENT
0
Entering edit mode
John ▴ 30
@john-9676
Last seen 5.9 years ago

Thanks Michael.

ADD COMMENT

Login before adding your answer.

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