select_l {tinylens} | R Documentation |
This function returns a lens that selects the specified columns. Requires
tidyselect
to be installed.
select_l(...)
... |
Columns to select |
A lens that selects the specified columns
d <- data.frame(x = 1:10, y = 11:20, z = 21:30)
l <- select_l(x, y)
# get the x and y columns
view(d, l)
# set the x and y columns
set(d, l, 1)