autoplot_methods: Autoplot methods for tornado plots

Description Usage Arguments Value Examples

Description

Autoplot methods for tornado plots

Usage

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
## S3 method for class 'tornado_df'
autoplot(object, ..., facet = TRUE, x_scale = TRUE, y_scale = TRUE)

## S3 method for class 'TornadoExperiment'
autoplot(
  object,
  ...,
  upper = "q0.99",
  lower = 0,
  scale_title = "Coverage",
  scale = NULL
)

Arguments

object

A TornadoExperiment or tornado_df object.

...

Used in the TornadoExperiment method to pass the facet, x_scale and y_scale arguments to the tornado_df method.

facet

A logical(1) or ggplot2 facet. If TRUE, a facet_tornado() is added. If FALSE, no facet will be added. When a ggplot2 facet, the facet is added to the plot.

x_scale

A logical(1) or ggplot2 x scale. If TRUE, an x scale is added that attempts to avoid overlapping labels.

y_scale

A logical(1) or ggplot2 y scale. If TRUE, a y scale is added that marks regular intervals but only labels the number of features.

upper

Limits to the colour scale. Can be one of the following:

  • A numeric to set absolute limits directly.

  • A character in the form of a number prefixed by "p" or "q" to set the percentile or quantile respectively. For example, "p99" and "q0.95" set the limit to the 99th percentile or 0.95th quantile respectively. The limits as specified in the lower and upper arguments can be overridden if the scale argument has non-default limits.

lower

Limits to the colour scale. Can be one of the following:

  • A numeric to set absolute limits directly.

  • A character in the form of a number prefixed by "p" or "q" to set the percentile or quantile respectively. For example, "p99" and "q0.95" set the limit to the 99th percentile or 0.95th quantile respectively. The limits as specified in the lower and upper arguments can be overridden if the scale argument has non-default limits.

scale_title

A character(1) with the title for the colourbar. Can be overridden when the scale argument has a non-default name.

scale

A continuous fill scale from the ggplot2 package to use to colour the tornado. When NULL (default), the scale will be retrieved from the option "tornadoplot.default.scale".

Value

A ggplot object.

Examples

1

teunbrand/tornadoplot documentation built on Dec. 23, 2021, 8:48 a.m.