Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add optional feature to fill nulls in Arrow::Array#to_narray #3

Open
mrkn opened this issue Aug 8, 2019 · 1 comment
Open

Add optional feature to fill nulls in Arrow::Array#to_narray #3

mrkn opened this issue Aug 8, 2019 · 1 comment

Comments

@mrkn
Copy link
Member

mrkn commented Aug 8, 2019

Currently Arrow::Array#to_narray raises an error when the receiver array has nulls.
I'd like to make this method to fill all the nulls by a specific value.

My API proposal is here:

nary = ary.to_narray(fillna: 0)  # filling nulls by 0
nary = ary.to_narray(fillna: Float::NAN)  # filling nulls by NaN
@kou
Copy link
Member

kou commented Aug 8, 2019

The feature should exist inArrow::Array. But not yet for now. https://issues.apache.org/jira/browse/ARROW-1567

Example:

arrow_array.fill_null(0).to_narray

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants