powered by
Set or return by layer binding
get_by(layer)set_by(layer, by)
set_by(layer, by)
For get_by, the by binding of the supplied layer. For
get_by
by
set_by the modified layer environment.
set_by
A tplyr_layer object
tplyr_layer
A string, a variable name, or a list of variable names supplied using dplyr::vars.
dplyr::vars
# Load in pipe library(magrittr) iris$Species2 <- iris$Species lay <- tplyr_table(iris, Species) %>% group_count(Species) %>% set_by(vars(Species2, Sepal.Width))
Run the code above in your browser using DataLab