Learn R Programming

XGR (version 1.1.4)

xVolcano: Function to draw a volcano plot

Description

xVolcano is supposed to draw a volcano plot

Usage

xVolcano(data, column.lfc = "lfc", column.fdr = "fdr", cutoff.lfc = 1,
cutoff.fdr = 0.05, colors = c("#EEEEEE", "darkgrey", "pink", "red"),
column.label = NULL, top = 10, top.direction = c("both", "up", "down"),
label.size = 2, label.color = "black", label.alpha = 0.8,
label.padding = 0.5, label.arrow = 0.01, label.force = 0.5,
xlim = NULL, ylim = NULL, y.scale = c("normal", "log"),
xlab = expression(log[2]("fold change")),
ylab = expression(-log[10]("FDR")), font.family = "sans",
signature = TRUE)

Arguments

data

a data frame

column.lfc

a character specifying 'lfc' column (log2-transformed fold change)

column.fdr

a character specifying 'fdr' column

cutoff.lfc

a numeric defining 'lfc' cutoff. By default, it is 1 (at least 2-fold changes)

cutoff.fdr

a numeric defining 'fdr' cutoff. By default, it is 0.05

colors

a 4-element vector for color-coded points. By default, it is c("#EEEEEE","darkgrey","pink","red")

column.label

a character specifying 'label' column

top

an integer specifying the number of the top points for labellings

top.direction

the direction (up- and down-regulated) of the top points. It can be one of 'both' (up- and down-regulated), 'up' (up-regulated only) and 'down' (down-regulated only)

label.size

the label size

label.color

the label color

label.alpha

the 0-1 value specifying transparency of labelling

label.padding

the padding around the labeled

label.arrow

the arrow pointing to the labeled

label.force

the repelling force between overlapping labels

xlim

the limits in the x-axis

ylim

the limits in the y-axis

y.scale

how to transform the y scale. It can be "normal" for no transformation, and "log" for log-based transformation

xlab

the x labelling. By default, it is expression(log[2]("fold change"))

ylab

the y labelling. By default, it is expression(-log[10]("FDR"))

font.family

the font family for texts

signature

logical to indicate whether the signature is assigned to the plot caption. By default, it sets TRUE

Value

a ggplot object

See Also

xVolcano

Examples

Run this code
# NOT RUN {
# Load the library
library(XGR)
RData.location <- "http://galahad.well.ox.ac.uk/bigdata/"
# }

Run the code above in your browser using DataLab