plotCnvLineplot.Rd
Plots the results of runCNV()
in form of a lineplot.
Use arguments across
and across_subset
to visualize CNV differences
between subgroups of cluster variables or other grouping variables (e.g. based on
histology created with createSpatialSegmentation()
).
plotCnvLineplot(
object,
across = NULL,
across_subset = NULL,
arm_subset = c("p", "q"),
chrom_subset = 1:22,
chrom_separate = 1:22,
chrom_arm_subset = NULL,
smooth_span = 0.08,
line_alpha = 0.9,
line_color = "blue",
line_size = 1,
display_ribbon = TRUE,
ribbon_alpha = 0.25,
ribbon_fill = "lightgrey",
vline_alpha = 0.75,
vline_color = "black",
vline_size = 0.5,
vline_type = "dashed",
summarize_with = "mean",
nrow = NULL,
ncol = NULL,
breaks_y = c(0.9, 0.95, 1, 1.05, 1.1),
labels_y = breaks_y,
limits_y = base::range(breaks_y),
expand_y = ggplot2::waiver(),
verbose = TRUE,
...
)
An object of class SPATA2
or, in case of S4 generics,
objects of classes for which a method has been defined.
Character value or NULL. Specifies the grouping variable of interest.
Use getGroupingOptions()
to obtain all variable names that group the
barcode spots of your object in a certain manner.
Character vector or NULL. Specifies the particular groups
of interest the grouping variable specified in argument across
contains.
If set to NULL all of them are chosen. You can prefix groups you are NOT interested in with a '-'. (Saves writing if there are more groups you are interested in than groups you are not interested in.)
Use getGroupNames()
to obtain all valid input options.
Character vector. A combination of 'p' and/or 'q'. Denotes which chromosome arms are included. Defaults to both.
Character or numeric vector. Denotes the chromosomes that are included. Defaults to all 1-22.
Character or numeric vector. Denotes the chromosomes that
are separated from their neighbors by vertical lines. Defaults to all 1-22. If FALSE or NULL,
no vertical lines are drawn. Requires display_vlines
to be set to TRUE.
Character vector. Denotes the exact chromosome-arm combinations that are included.
Numeric value. Controls the degree of smoothing.
Given to argument span
of stats::loess()
.
Numeric. Affects alpha of main lines of the plot.
Character. Affects color of the main lines of the plot.
Numeric. Affects size of the main lines of the plot.
Logical value. If TRUE, a ribbon is displayed around the main line of the plot visualizing uncertainty using standard deviation.
Parameters given to ggplot2::geom_ribbion()
that control the appearance of the ribbon around the main line of the plot.
Parameters given to
ggplot2::geom_vline()
that control the appearance of vertical lines
of the plot.
Character value. Name of the function with which to summarize. Either 'mean' or 'median'.
Numeric values or NULL. Used to arrange multiple plots.
Given to the corresponding arguments
of ggplot2::scale_y_continuous()
.
Logical. If TRUE
, informative messages regarding
the computational progress will be printed.
(Warning messages will always be printed.)
Used to absorb deprecated arguments or functions.
A ggplot.
Extensive tutorials for how to use this function can be found on our website https://themilolab.github.io/SPATA2/ .