plot.hstats_matrix {hstats}R Documentation

Plots "hstats_matrix" Object

Description

Plot method for objects of class "hstats_matrix".

Usage

## S3 method for class 'hstats_matrix'
plot(
  x,
  top_m = 15L,
  fill = getOption("hstats.fill"),
  swap_dim = FALSE,
  viridis_args = getOption("hstats.viridis_args"),
  facet_scales = "fixed",
  ncol = 2L,
  rotate_x = FALSE,
  err_type = c("SE", "SD", "No"),
  ...
)

Arguments

x

An object of class "hstats_matrix".

top_m

How many rows should be plotted? Inf for all.

fill

Fill color of ungrouped bars. The default equals the global option hstats.fill = "#fca50a". To change the global option, use ⁠options(stats.fill = new value)⁠.

swap_dim

Switches the role of grouping and facetting (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()]⁠.

ncol

Passed to ⁠[ggplot2::facet_wrap()]⁠.

rotate_x

Should x axis labels be rotated by 45 degrees?

err_type

The error type to show, by default "SE" (standard errors). Set to "SD" for standard deviations (SE * sqrt(m_rep)), or "No" for no bars. Currently, supported only for perm_importance().

...

Passed to ggplot2::geom_bar().

Value

An object of class "ggplot".


[Package hstats version 1.1.2 Index]