The function creates a 'four quadrant' volcano plot, where the FDR and log2FoldChange thresholds dictate the significant up-regulated category, the significant downregulated category, the significant low regulation category and the non-significant category

Genes of interest are labeled in a rectangle for visibility and will have the same color as the category in which they are in. Top significant genes are also labelled in rectangles but will have black text in order to distinguish them from the genes of interest

The plot is created using ggplot2, to save a plot the ggsave() function is recommended It is also recommended to use the following parameters to save the plot. dpi=300 width=21 height=19 units='cm'

volcanoplot_alt(
  DE_res,
  genes_of_interest = c(),
  filter_choice = "padj",
  l2FC_thresh = 1,
  p_thresh = 0.05,
  plot_title = "Volcano plot",
  label_top_n = 0,
  show_non_sig_interest = TRUE
)

Arguments

DE_res

The differential expression results to be plotted

genes_of_interest

A vector containing gene names to be labelled in the plot To not label any genes, leave as default or provide an empty vector.

filter_choice

Either padj or pvalue, the choice will be used to filter for significance

l2FC_thresh

The log2FoldChange threshold used to establish significance

p_thresh

The pvalue or padj threshold used to establish significance

plot_title

The title to be give to the plot

label_top_n

The number of genes to label. Genes will be taken in order of significance where the genes with the lowest adjusted p-value are taken first.

show_non_sig_interest

A boolean to indicate if the non-significant genes of interest should be shown.

Value

The ggplot object for the volcano plot

Examples

TS_object<-create_example_object_for_R()
TS_object <- normalize_timeSeries_with_deseq2(time_object=TS_object)
#> converting counts to integer mode
#Perform conditional differential gene expression analysis
TS_object<-conditional_DE_wrapper(TS_object,vignette_run=TRUE)
DE_res<-slot(TS_object,'DE_results')$conditional$IgM_vs_LPS_TP_1$DE_raw_data
v_plot<-volcanoplot_alt(DE_res = DE_res)