-
Notifications
You must be signed in to change notification settings - Fork 590
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
FEAT: Support custom window in pandas backend #2260
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
lgtm, added few minor suggestions.
I guess we want to add a release note for this, can you add it please? Thanks!
| expected_1 = pd.Series([4.0, 10.0, 5.0]) | ||
|
|
||
| tm.assert_series_equal(result_0, expected_0) | ||
| tm.assert_series_equal(result_1, expected_1) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Not sure if it'd be more conventional to use a fixture for all the custom objects, and parameterize this. But happy to have it like this, if we don't expect to reuse all the custom objects.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
can also parametrize this test with the different cases
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Made those fixtures
|
Thanks @jreback @datapythonista for the review! I addressed all the comments. Please take another look when you got the chance, thank you! |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
lgtm, thanks @icexelloss
Co-authored-by: Marc Garcia <garcia.marc@gmail.com>
Co-authored-by: Marc Garcia <garcia.marc@gmail.com>
c942424
to
532d8c3
Compare
|
thanks @icexelloss |
This PR refactors the existing pandas window execution to allow implementing custom window with pandas backend.
The change is tested with a new test
test_custom_window_udfwhich implements a dummy custom window and test it with pandas backend.