Uses the design of a lineplot to visualize feature dynamics over time across a grouping variable of interest.

plotTimeLineplot(
  object,
  variables,
  across = "condition",
  across_subset = NULL,
  relevel = NULL,
  summarize_with = "mean",
  phase = NULL,
  linesize = 1,
  scales = "free_y",
  nrow = NULL,
  ncol = NULL,
  smooth = TRUE,
  smooth_method = "loess",
  smooth_span = 0.25,
  smooth_se = FALSE,
  display_vline = TRUE,
  vline_clr = "lightgrey",
  vline_type = "dashed",
  clrp = "milo",
  verbose = TRUE,
  ...,
  in_shiny = FALSE
)

Arguments

object

A valid cypro object.

variables

Character vector. Denotes the track variables whoose summary you want to display over time. Use getTrackVariableNames() to obtain all valid input options.

across

Character value, character vector or NULL (see details for more). Specifies the grouping variable of interest.

Use getGroupingVariableNames() to obtain all variable names that group the cells of your experiment in a certain manner.

across_subset

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.

relevel

Logical value. If set to TRUE the input order of across_subset determines the order in which the groups of interest are displayed. Groups that are not included are dropped which affects the choice of color.

summarize_with

Character value. One of 'mean', 'median', 'max' or 'min'.

phase

Character or numeric. If character, the ordinal value referring to the phase of interest (e.g. 'first', 'second' etc.). referring to the phase of interest or 'all'. If numeric, the number referring to the phase.

If set to NULL takes the phase denoted as default with adjustDefault().

Ignored if the experiment design contains only one phase.

linesize

Numeric value. Denotes the size of the lines drawn.

scales

Given to ggplot2::facet_wrap(). Affects the way the subplots are displayed.

nrow

Given to ggplot2::facet_wrap(). Affects the way the subplots are displayed.

ncol

Given to ggplot2::facet_wrap(). Affects the way the subplots are displayed.

smooth

Logical. If set to TRUE the values are smoothed.

smooth_method

Character value. Denotes the model type used to display the line. Defaults to 'lm' (linear model). Given to argument method of function ggplot2::geom_smooth().

smooth_span

NUmeric value. Denotes the smoothing span used.

smooth_se

Logical. If set to TRUE the standard error will be displayed.

display_vline

Logical value. If set to TRUE and more than one phase is referred to a vertical line is displayed hihglighting the phase separation.

vline_clr

Character value. Color of the vertical line.

vline_type

Character value. Defaults to 'dashed'.

clrp

Character value. Specifies the color palette to be used to represent groups of discrete variables. Run validColorPalettes() to obtain valid input options.

verbose

Logical. If set to TRUE informative messages regarding the computational progress will be printed.

(Warning messages will always be printed.)

Value

A ggplot.