volcano_plot: Volcano plot

Description Usage Arguments Details

Description

'volcano_plot' prints a volcano plot using a data frame containing p-values and foldchanges

Usage

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
volcano_plot(
  volcano_df,
  foldchange_col,
  significance_col,
  significance = 0.05,
  foldchange = 1,
  title = "Volcano plot",
  x_lab = "log2Foldchange",
  y_lab = "-log10(p-value)",
  labels = TRUE,
  out_path = "none"
)

Arguments

volcano_df

data frame.

foldchange_col

vector. Column of volcano_df containing the foldchange values. Format: volcano_df$foldchange_col

significance_col

vector. Column of volcano_df containing the p-values. Format: volcano_df$significance_col

significance

numeric. Value for the significance threshold. Default = 0.05.

foldchange

numeric. Vaue for the foldchange threshold. Default = #todo

title

string. Main title. Default = "Volcano plot"

x_lab

string. x-axix title. Default = "log2Fold"

y_lab

string. y-axis title- Default = "-log10(p-value)"

labels

logical. Should the points over the threshold be labelled. Options: TRUE (default), FALSE

out_path

string. Path to save plot to png. If out_path is empty, the plot is printed to the device. If "none", the plot is either printed or saved to a variabe.

Details

This function takes a data frame with columns for p-values and (log2)foldchanges and returns a dotplot resembelling a volcano plot. It uses the given significance and foldchange threshods to mark significantly up- and down-regulated elements by color and by displaying threshold lines.


lisaschneider0509/lipidomeComparisonR documentation built on Aug. 12, 2020, 12:52 a.m.