ply_aes: Compute aesthetics groupwise

Description Usage Arguments Details

Description

ply_aes causes the aesthetics of a layer to be computed groupwise. ply_aes implements the split-apply-combine strategy of data analysis in a graphical framework. It first splits a layer's data frame into subgroups, then evaluates the layers mappings separately within each group, and finally combines the results into a single data frame which is used to build the plot for rendering.

Usage

1
  ply_aes(layer, .vars = NULL)

Arguments

layer

a ggplot2 layer or glayer object. This layer's aesthetics will be computed groupwise, but the layer will remain the same in every other respect.

.vars

variable names to group by (optional), stored as a character string

Details

Users may specify which groupings to use through the .vars argument. If this argument is left NULL, ply_aes will search for and use a group aes, a glyphing or gridding criteria (in a glayer), a facetting criteria, or any combination of these that it finds.


garrettgman/ggplyr documentation built on May 16, 2019, 5:38 p.m.