Visualizes values stored in the colData slot of a SingleCellExperiment object via a density plot.
plotSCEDensityColData(
inSCE,
coldata,
sample = NULL,
groupBy = NULL,
xlab = NULL,
ylab = NULL,
baseSize = 12,
axisSize = NULL,
axisLabelSize = NULL,
defaultTheme = TRUE,
title = NULL,
titleSize = 18,
cutoff = NULL,
combinePlot = "none",
plotLabels = NULL
)
Input SingleCellExperiment object with saved dimension reduction components or a variable with saved results. Required.
colData value that will be plotted.
Character vector. Indicates which sample each cell belongs to.
Groupings for each numeric value. A user may input a vector equal length to the number of the samples in the SingleCellExperiment object, or can be retrieved from the colData slot. Default NULL.
Character vector. Label for x-axis. Default NULL.
Character vector. Label for y-axis. Default NULL.
The base font size for all text. Default 12. Can be overwritten by titleSize, axisSize, and axisLabelSize, legendSize, legendTitleSize.
Size of x/y-axis ticks. Default NULL.
Size of x/y-axis labels. Default NULL.
Removes grid in plot and sets axis title size to 10 when TRUE. Default TRUE.
Title of plot. Default NULL.
Size of title of plot. Default 15.
Numeric value. The plot will be annotated with a vertical line if set. Default NULL.
Must be either "all", "sample", or "none". "all" will combine all plots into a single .ggplot object, while "sample" will output a list of plots separated by sample. Default "none".
labels to each plot. If set to "default", will use the name of the samples as the labels. If set to "none", no label will be plotted.
a ggplot of the density plot of colData.
data("mouseBrainSubsetSCE")
plotSCEDensityColData(
inSCE = mouseBrainSubsetSCE,
coldata = "age", groupBy = "sex"
)
#> [[1]]
#>