Plot method for objects of class "ice".

# S3 method for class 'ice'
plot(
  x,
  center = FALSE,
  alpha = 0.2,
  color = getOption("hstats.color"),
  swap_dim = FALSE,
  viridis_args = getOption("hstats.viridis_args"),
  facet_scales = "fixed",
  rotate_x = FALSE,
  ...
)

Arguments

x

An object of class "ice".

center

Should curves be centered? Default is FALSE.

alpha

Transparency passed to ggplot2::geom_line().

color

Color of lines and points (in case there is no color/fill aesthetic). The default equals the global option hstats.color = "#3b528b". To change the global option, use options(stats.color = new value).

swap_dim

Swaps between color groups and facets. Default is FALSE.

viridis_args

List of viridis color scale arguments, see [ggplot2::scale_color_viridis_d()]. The default points to the global option hstats.viridis_args, which corresponds to list(begin = 0.2, end = 0.8, option = "B"). E.g., to switch to a standard viridis scale, you can change the default via options(hstats.viridis_args = list()), or set viridis_args = list().

facet_scales

Value passed as scales argument to [ggplot2::facet_wrap()].

rotate_x

Should x axis labels be rotated by 45 degrees?

...

Passed to ggplot2::geom_bar().

Value

An object of class "ggplot".

See also

See ice() for examples.