Skip to content

Fix DataArray.to_dataframe when the array has MultiIndex #4442

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

Merged
merged 9 commits into from
Feb 20, 2021

Conversation

ghislainp
Copy link
Contributor

@ghislainp ghislainp commented Sep 20, 2020

Copy link
Member

@shoyer shoyer left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This looks like a nice improvement! It will also need unit test(s) to verify that it works.

@pep8speaks
Copy link

pep8speaks commented Sep 21, 2020

Hello @ghislainp! Thanks for updating this PR. We checked the lines you've touched for PEP 8 issues, and found:

There are currently no PEP 8 issues detected in this Pull Request. Cheers! 🍻

Comment last updated at 2021-02-19 23:01:55 UTC

Copy link
Member

@shoyer shoyer left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The continuous integration tests are failing because this isn't formatted according to black. Please run black . to fix that.

@shoyer
Copy link
Member

shoyer commented Sep 28, 2020

This looks good to me!

The last (optional) part is adding an entry in xarray's release notes -- see docs/whats-new.rst

@dcherian dcherian changed the title Coordinates.to_index now accepts MultiIndex. Solve issue in DataArray.to_dataframe when the array has MultiIndex Fix DataArray.to_dataframe when the array has MultiIndex Dec 16, 2020
@dcherian
Copy link
Contributor

dcherian commented Dec 16, 2020

@ghislainp can you add a note to whats-new and merge master please? (I can't push to your branch for some reason)

@dcherian
Copy link
Contributor

Thanks @ghislainp and @keewis!

@ghislainp sorry for the delay here

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

Successfully merging this pull request may close these issues.

to_dataframe/to_series fails when one out of more than one dims are stacked / multiindex
5 participants