Skip to content

Commit 8100859

Browse files
authored
Mark aes() and vars() as <data-masking> (#5153)
* Mark aes/vars as <data-masking> * Roxygenate
1 parent 1e1b6b1 commit 8100859

File tree

4 files changed

+24
-20
lines changed

4 files changed

+24
-20
lines changed

R/aes.r

Lines changed: 8 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -22,13 +22,14 @@ NULL
2222
#' programming vignette](https://dplyr.tidyverse.org/articles/programming.html)
2323
#' to learn more about these techniques.
2424
#'
25-
#' @param x,y,... List of name-value pairs in the form `aesthetic = variable`
26-
#' describing which variables in the layer data should be mapped to which
27-
#' aesthetics used by the paired geom/stat. The expression `variable` is
28-
#' evaluated within the layer data, so there is no need to refer to
29-
#' the original dataset (i.e., use `ggplot(df, aes(variable))`
30-
#' instead of `ggplot(df, aes(df$variable))`). The names for x and y aesthetics
31-
#' are typically omitted because they are so common; all other aesthetics must be named.
25+
#' @param x,y,... <[`data-masking`][rlang::topic-data-mask]> List of name-value
26+
#' pairs in the form `aesthetic = variable` describing which variables in the
27+
#' layer data should be mapped to which aesthetics used by the paired
28+
#' geom/stat. The expression `variable` is evaluated within the layer data, so
29+
#' there is no need to refer to the original dataset (i.e., use
30+
#' `ggplot(df, aes(variable))` instead of `ggplot(df, aes(df$variable))`).
31+
#' The names for x and y aesthetics are typically omitted because they are so
32+
#' common; all other aesthetics must be named.
3233
#' @seealso [vars()] for another quoting function designed for
3334
#' faceting specifications.
3435
#'

R/facet-.r

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -185,9 +185,10 @@ Facet <- ggproto("Facet", NULL,
185185
#' represents or the results of the expressions) are used to form
186186
#' faceting groups.
187187
#'
188-
#' @param ... Variables or expressions automatically quoted. These are
189-
#' evaluated in the context of the data to form faceting groups. Can
190-
#' be named (the names are passed to a [labeller][labellers]).
188+
#' @param ... <[`data-masking`][rlang::topic-data-mask]> Variables or
189+
#' expressions automatically quoted. These are evaluated in the context of the
190+
#' data to form faceting groups. Can be named (the names are passed to a
191+
#' [labeller][labellers]).
191192
#'
192193
#' @seealso [aes()], [facet_wrap()], [facet_grid()]
193194
#' @export

man/aes.Rd

Lines changed: 8 additions & 7 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

man/vars.Rd

Lines changed: 4 additions & 3 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)