-
Notifications
You must be signed in to change notification settings - Fork 3.6k
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
[C++] Implement cumulative sum compute function #29183
Comments
Antoine Pitrou / @pitrou: |
Eduardo Ponce / @edponce:
|
Eduardo Ponce / @edponce: |
Eduardo Ponce / @edponce:
|
Weston Pace / @westonpace: We don't really support nested<->nested arithmetic elsewhere do we?
|
Eduardo Ponce / @edponce: |
Eduardo Ponce / @edponce: # Valid values
>>> pc.cumulative_sum([1,2,3,4,5])
<pyarrow.lib.Int64Array object at 0x12622c7c0>
[
1,
3,
6,
10,
15
]
# Nulls and values
>>> pc.cumulative_sum([1,2,None,3,None,5], skip_nulls=True)
<pyarrow.lib.Int64Array object at 0x12622c760>
[
1,
3,
null,
6,
null,
11
]
>>> pc.cumulative_sum([1,2,None,3,None,5], skip_nulls=False)
<pyarrow.lib.Int64Array object at 0x12622c700>
[
1,
3,
null,
null,
null,
null
]
# NaN followed by nulls and values
>>> pc.cumulative_sum([1,np.nan,None,3,None,5], skip_nulls=True)
<pyarrow.lib.DoubleArray object at 0x12622c640>
[
1,
nan,
null,
nan,
null,
nan
]
>>> pc.cumulative_sum([1,np.nan,None,3,None,5], skip_nulls=False)
<pyarrow.lib.DoubleArray object at 0x12622c700>
[
1,
nan,
null,
null,
null,
null
]
Behavior of
|
Krisztian Szucs / @kszucs: |
Antoine Pitrou / @pitrou: |
Reporter: Antoine Pitrou / @pitrou
Assignee: Jabari Booker / @JabariBooker
Related issues:
PRs and other links:
Note: This issue was originally created as ARROW-13530. Please see the migration documentation for further details.
The text was updated successfully, but these errors were encountered: