.ggCellViolin {rliger}R Documentation

Produce single violin plot with data frame passed from upstream

Description

Produce single violin plot with data frame passed from upstream

Usage

.ggCellViolin(
  plotDF,
  y,
  groupBy = NULL,
  colorBy = NULL,
  violin = TRUE,
  violinAlpha = 0.8,
  violinWidth = 0.9,
  box = FALSE,
  boxAlpha = 0.6,
  boxWidth = 0.4,
  dot = FALSE,
  dotColor = "black",
  dotSize = getOption("ligerDotSize"),
  raster = NULL,
  seed = 1,
  ...
)

Arguments

plotDF

Data frame like object (fortifiable) that contains all necessary information to make the plot.

y, groupBy, colorBy

See plotCellViolin.

violin, box, dot

Logical, whether to add violin plot, box plot or dot (scatter) plot, respectively. Layers are added in the order of dot, violin, and violin on the top surface. By default, only violin plot is generated.

violinAlpha, boxAlpha

Numeric, controls the transparency of layers. Default 0.8, 0.6, respectively.

violinWidth, boxWidth

Numeric, controls the width of violin/box bounding box. Default 0.9 and 0.4.

dotColor, dotSize

Numeric, globally controls the appearance of all dots. Default "black" and getOption("ligerDotSize") (1).

raster

Logical, whether to rasterize the dot plot. Default NULL automatically rasterizes the dot plot when number of total cells to be plotted exceeds 100,000.

seed

Random seed for reproducibility. Default 1.

...

More theme setting arguments passed to .ggplotLigerTheme.

Value

ggplot object by default. When plotly = TRUE, returns plotly (htmlwidget) object.


[Package rliger version 2.0.1 Index]