Learn R Programming

g2r (version 0.1.0)

asp: Aspects

Description

Chart's aspects, similar to ggplot2's aesthetics.

Usage

asp(x, y, ...)

Arguments

x, y, ...

List of name value pairs giving aspects to map to variables. The names for x and y aspects are typically omitted because they are so common; all other aspects must be named.

Figures

  • x, y

  • size

  • color

  • shape

  • opacity

  • adjust

  • tooltip

  • label

  • style

  • group

Info

  • x, y

  • xend, yend

  • content

  • offset_x

  • offset_y

  • html

  • z_index

  • align_x

  • align_y

  • top

  • color

Details

Aspects can be applied to figures and to info, note that those can be inherited in the former but not the latter.

Examples

Run this code
# NOT RUN {
g2(temp, asp(month, temp, color = city)) %>% 
  fig_interval(adjust("dodge"))

# }

Run the code above in your browser using DataLab