geom_tornado: Tornado Heatmap

Description Usage Arguments Details Value Aesthetics Examples

View source: R/methods_plotting.R

Description

geom_tornado() serves as a plotting layer for tornado heatmaps.

Usage

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
geom_tornado(
  mapping = NULL,
  data = NULL,
  position = "identity",
  ...,
  interpolate = FALSE,
  na.rm = FALSE,
  show.legend = NA,
  inherit.aes = TRUE
)

Arguments

mapping

Set of aesthetic mappings created by aes() or aes_(). If specified and inherit.aes = TRUE (the default), it is combined with the default mapping at the top level of the plot. You must supply mapping if there is no plot mapping.

data

A tornado_df data.frame, such as one that results from processing a tornado array with prep_tornado().

position

Position adjustment, either as a string, or the result of a call to a position adjustment function.

...

Other arguments passed on to layer(). These are often aesthetics, used to set an aesthetic to a fixed value, like colour = "red" or size = 3. They may also be parameters to the paired geom/stat.

interpolate

If TRUE interpolate linearly, if FALSE (the default) don't interpolate.

na.rm

If FALSE, the default, missing values are removed with a warning. If TRUE, missing values are silently removed.

show.legend

logical. Should this layer be included in the legends? NA, the default, includes if any aesthetics are mapped. FALSE never includes, and TRUE always includes. It can also be a named logical vector to finely select the aesthetics to display.

inherit.aes

If FALSE, overrides the default aesthetics, rather than combining with them. This is most useful for helper functions that define both data and aesthetics and shouldn't inherit behaviour from the default plot specification, e.g. borders().

Details

The required aesthetics are synonymous with the column names of a default tornado_df.

Value

A GeomTornado ggproto object that can be added to a plot.

Aesthetics

geom_tornado understands the following aesthetics (required aesthetics are in bold):

Examples

1

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