diff --git a/r/R/dplyr-funcs-doc.R b/r/R/dplyr-funcs-doc.R index cbfe475232b..5360c7fad66 100644 --- a/r/R/dplyr-funcs-doc.R +++ b/r/R/dplyr-funcs-doc.R @@ -185,7 +185,7 @@ #' #' ## dplyr #' -#' * [`across()`][dplyr::across()]: supported inside `mutate()`, `summarize()`, `group_by()`, and `arrange()`; +#' * [`across()`][dplyr::across()]: not yet supported inside `filter()`; #' purrr-style lambda functions #' and use of `where()` selection helper not yet supported #' * [`between()`][dplyr::between()] diff --git a/r/data-raw/docgen.R b/r/data-raw/docgen.R index 9f839cfd123..267a85bdabe 100644 --- a/r/data-raw/docgen.R +++ b/r/data-raw/docgen.R @@ -128,8 +128,8 @@ docs <- arrow:::.cache$docs # across() is handled by manipulating the quosures, not by nse_funcs docs[["dplyr::across"]] <- c( - # TODO(ARROW-17387, ARROW-17389, ARROW-17390): other verbs - "supported inside `mutate()`, `summarize()`, `group_by()`, and `arrange()`;", + # TODO(ARROW-17387): do filter + "not yet supported inside `filter()`;", # TODO(ARROW-17366): do ~ "purrr-style lambda functions", # TODO(ARROW-17384): implement where diff --git a/r/man/acero.Rd b/r/man/acero.Rd index 5d4859edcb5..76f1b13fe3a 100644 --- a/r/man/acero.Rd +++ b/r/man/acero.Rd @@ -175,7 +175,7 @@ as \code{arrow_ascii_is_decimal}. \subsection{dplyr}{ \itemize{ -\item \code{\link[dplyr:across]{across()}}: supported inside \code{mutate()}, \code{summarize()}, \code{group_by()}, and \code{arrange()}; +\item \code{\link[dplyr:across]{across()}}: not yet supported inside \code{filter()}; purrr-style lambda functions and use of \code{where()} selection helper not yet supported \item \code{\link[dplyr:between]{between()}} diff --git a/r/tests/testthat/test-dplyr-distinct.R b/r/tests/testthat/test-dplyr-distinct.R index c679794d419..b598d058901 100644 --- a/r/tests/testthat/test-dplyr-distinct.R +++ b/r/tests/testthat/test-dplyr-distinct.R @@ -90,6 +90,16 @@ test_that("distinct() can contain expressions", { ) }) +test_that("across() works in distinct()", { + compare_dplyr_binding( + .input %>% + distinct(across(starts_with("d"))) %>% + collect() %>% + arrange(dbl, dbl2), + tbl + ) +}) + test_that("distinct() can return all columns", { skip("ARROW-14045") compare_dplyr_binding(