nest.dtplyr_step | R Documentation |
This is a method for the tidyr tidyr::nest()
generic. It is translated
using the non-nested variables in the by
argument and .SD
in the j
argument.
## S3 method for class 'dtplyr_step'
nest(.data, ..., .names_sep = NULL, .key = deprecated())
.data |
A data frame. |
... |
< |
.names_sep |
If |
.key |
Not supported. |
data |
A |
if (require("tidyr", quietly = TRUE)) {
dt <- lazy_dt(tibble(x = c(1, 2, 1), y = c("a", "a", "b")))
dt %>% nest(data = y)
dt %>% dplyr::group_by(x) %>% nest()
}
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.