-
-
Notifications
You must be signed in to change notification settings - Fork 18.4k
NDFrame.interpolate(): variable 'ax' not assigned when axis='index' #29132
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
Comments
Thanks for the report, confirmed on master. We should have an |
@TomAugspurger do you mean something like this? Also: there doesn't seem to be a whatsnew file since 0.25.2, does this go into v0.25.3.rst?
Edit: sorry @gabriellm1 I didn't see your comment! |
whatsnew will go in v1.0.0.rst
…On Mon, Oct 21, 2019 at 3:59 PM ellequelle ***@***.***> wrote:
@TomAugspurger <https://github.com/TomAugspurger> do you mean something
like this? Also: there doesn't seem to be a whatsnew file since 0.25.2,
does this go into v0.25.3.rst?
axis = self._get_axis_number(axis)
if axis == 0:
ax = self._info_axis_name
_maybe_transposed_self = self
elif axis == 1:
_maybe_transposed_self = self.T
ax = 1
else:
ax = axis
_maybe_transposed_self = self
ax = _maybe_transposed_self._get_axis_number(ax)
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
<#29132?email_source=notifications&email_token=AAKAOIUOC55VGO2P4XPEPQ3QPYJ2TA5CNFSM4JC7IVS2YY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOEB3YWGA#issuecomment-544705304>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AAKAOISKWQ3QQ7MB53HPSNLQPYJ2TANCNFSM4JC7IVSQ>
.
|
NDFrame.interpolate fails if axis is specified by name and not integer
Hi, I'm new to pandas development (but a fan). Can I try this as part of #hacktoberfest, and where do I start? |
The
NDFrame.interpolate
function fails when passing a string as axis. Example:From the documentation and from the function itself, it looks like
df.interpolate(axis='index')
was intended to work, but that maybe someone accidentally deleted a line in generic.py? The function seems to work properly if I addax = axis
in the else block here:pandas/pandas/core/generic.py
Lines 6998 to 7006 in 171c716
I am using pandas version 0.25.1
The text was updated successfully, but these errors were encountered: