agg_step: Add a step line layer to an arphit plot.

Description Usage Arguments See Also Examples

View source: R/gg-constructors.R

Description

Add a step line layer to an arphit plot.

Usage

1
2
agg_step(aes = NULL, data = NULL, colour = NULL, pch = NULL,
  lty = NULL, lwd = NULL, pointsize = 1, panel = "1")

Arguments

aes

The aesthetic that defines the layer. Will inherit (or parts thereof) if omitted.

data

The data to be used. Will inherit from parent if missing.

colour

A colour to be applied to all of the series, or (if your aesthetic has a group), a vector of colours that will be cycled through to consecutive group elements.

pch

A point marker to be applied to all series, or (if your aesthetic has a group), a vector of pch values that will be cycled through to consecutive group elements. Any value accepted by R for pch can be used.

lty

A line type to be applied to all series, or (if your aesthetic has a group), a vector of lty values that will be cycled through to consecutive group elements. Any value accepted by R for lty can be used.

lwd

A line width to be applied to all series, or (if your aesthetic has a group), a vector of lwd values that will be cycled through to consecutive group elements. Any value accepted by R for lwd can be used.

pointsize

Scale the size of the points? (default 1)

panel

(default = "1") Which panel of the graph to place this layer on. You can specify a vector of panels (e.g. 'panel = c("1","3")') to apply the layer to multiple panels at once.

See Also

vignette("plotting-options", package = "arphit") for a detailed description of all the plotting options

Examples

1
2
3
4
5
6
7
data  <- data.frame(unemployment = rnorm(20),
                    state = c(rep("A", 10), rep("B", 10)),
                    date = seq.Date(from = as.Date("2017-01-10"),
                                    length.out = 10,
                                    by = "quarter"))
arphitgg(data) +
  agg_step(agg_aes(x = date, y = unemployment, group = state), panel = "1")

angusmoore/arphit documentation built on Feb. 15, 2021, 9:40 a.m.