markfairbanks / tidytable

Tidy interface to 'data.table'
https://markfairbanks.github.io/tidytable/
Other
450 stars 32 forks source link

Implement `consecutive_id.()` #553

Closed markfairbanks closed 2 years ago

markfairbanks commented 2 years ago

A dplyr interface to data.table::rleid().

consecutive_id. <- function(...) {
  check_dots_unnamed()

  data <- data_frame(..., .name_repair = "minimal")

  rleidv(data)
}