--- title: "Volcano" author: "Alex Emmons, Ph.D." format: html: embed-resources: true code-fold: true code-tools: true code-overflow: wrap toc: true date: "January 17, 2024" date-modified: last-modified params: data: "./deseq2_DEGs.csv" --- # Volcano Quarto Demonstration Here we will create a volcano plot from differential expression results. ::: {.callout-tip} Labels are ensembl IDs. For a more useful figure, add an annotation step. ::: Learn more about Volcano plots [here](https://training.galaxyproject.org/training-material/topics/transcriptomics/tutorials/rna-seq-viz-with-volcanoplot/tutorial.html){target=_blank}. ## Create a Volcano Plot from DESeq2 differential expression results ### Load the libraries ```{r} #| message: false library(EnhancedVolcano) library(dplyr) ``` ### Load the data from command line arguments The data were filtered to remove adjusted p-values that were NA; these were genes excluded by `DESeq2` as a part of independent filtering. ```{r} data<-read.csv(params$data,row.names=1) %>% filter(!is.na(padj)) ``` ### Plot Create label subsets for plotting. ```{r} labs<-head(row.names(data),5) ``` @fig-volcano_plot allows us to identify which genes are statistically significant with large fold changes. ```{r} #| label: fig-volcano_plot #| fig-cap: "Enhanced Volcano Plot of bulk RNA-seq data from the package airway" #| warning: false EnhancedVolcano(data, title = "Enhanced Volcano with Airways", lab = rownames(data), selectLab=labs, labSize=3, drawConnectors = TRUE, x = 'log2FoldChange', y = 'padj') ``` Other files in this working directory: ```{bash} ls ```