apache / apache/arrow

[R] Support translations of simple data.table functions

Open
#45,098 2 comments 0 reactions 1 assignee Claimed by @MichaelChirico View on GitHub
Component: R Status: needs champion Status: stale-warning Type: enhancement
Dominant language
C++
Stars
17.1k
Forks
4.3k
Avg merge
3d 13h
Merged PRs (30d)
88

Description

### Describe the bug, including details regarding any error messages, version, and platform.

Related: #39822.
Context: https://github.com/MichaelChirico/funchir/issues/18

Goal: `acero` engine translates some {data.table} functions into {arrow} executions.

#39822 is much more ambitious since it requires implementing translation for the most complex part of the {data.table} API, namely `[`.

This request should be much simpler to satisfy -- at a minimum, translate `fcase()`, but we should also be able to do `fifelse()` and `fcoalesce()`. These have {dplyr} equivalents `case_when()`, `if_else()`, and `coalesce()`, respectively.

My assumption here is that acero works by static analysis -- read the AST, apply known translations, i.e. analogous to {dbplyr}. If there's something deeper going on then this is just a duplicate of #39822.

I can help prepare a PR but don't really have a machine suitable for that available until next year. Filing this issue first as a sanity check & to gauge interest.

### Component(s)

R

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.