alt_qplot: qplot for altair

Description Usage Arguments Details Value

View source: R/qplot.r

Description

alt_qplot is inspired by qplot from ggplot2, and is similarly intended to be a convenient wrapper for making many different kinds of plots with a simple and consistent interface. In this case, the generated plot is made via altair, instead of ggplot2.

Usage

1
2
alt_qplot(x, y, ..., data, mark = c("auto", "area", "bar", "circle",
  "geoshape", "line", "point", "rect", "rule", "square", "text", "tick"))

Arguments

x, y, ...

encodings. These should either be strings or symbols matching column names in data if data is provided, or a variable in the calling environment otherwise

data

a data.frame or tibble. If missing, the data for the plot will be taken from the encoding variables passed in.

mark

the mark to use. if "auto", will default to point except when only the y encoding is missing in which case the mark will default to bar and y will default to count()

Details

Paraphrasing the qplot documentation in ggplot, alt_qplot is great for allowing you to produce plots quickly, but I highly recommend learning altair as it makes it easier to create complex graphics.

Value

an altair plot specification


AliciaSchep/altqplot documentation built on May 30, 2019, 11:55 a.m.