You are viewing a plain text version of this content. The canonical link for it is here.
Posted to jira@arrow.apache.org by "Ian Cook (Jira)" <ji...@apache.org> on 2021/09/28 19:32:00 UTC
[jira] [Assigned] (ARROW-14036) [R] Binding for n_distinct() with
no grouping
[ https://issues.apache.org/jira/browse/ARROW-14036?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Ian Cook reassigned ARROW-14036:
--------------------------------
Assignee: Ian Cook
> [R] Binding for n_distinct() with no grouping
> ---------------------------------------------
>
> Key: ARROW-14036
> URL: https://issues.apache.org/jira/browse/ARROW-14036
> Project: Apache Arrow
> Issue Type: New Feature
> Components: R
> Reporter: Ian Cook
> Assignee: Ian Cook
> Priority: Critical
> Labels: kernel
> Fix For: 6.0.0
>
>
> ARROW-13620 added a binding for {{n_distinct()}} but it only works for _grouped_ aggregation, not whole-table aggregation.
> This works:
> {code:java}
> Table$create(starwars) %>%
> group_by(homeworld) %>%
> summarise(n_distinct(species)) %>%
> collect(){code}
> but this errors:
> {code:java}
> Table$create(starwars) %>%
> summarise(n_distinct(species)) %>%
> collect()
> #> Error: Key error: No function registered with name: count_distinct{code}
> Once we have a non-hash {{count_distinct}} aggregate kernel in the C++ library (ARROW-14035) we should bind the options for it in the R package and add a test.
--
This message was sent by Atlassian Jira
(v8.3.4#803005)