Repository navigation
Adding pandas Int64 support [fix #9280] - #9541
Conversation
|
Thanks! Test failure seems real, but change log can wait until the relevant section is available. I'll let subpackage maintainer decides if a new test is necessary. |
|
@bmorris3 - my sincere apologies for the late reply. This slipped off my radar and I just noticed it again today. This looks like a great direction and we should go forward on it. Some issues that need to be addressed are:
|
|
Hi humans 👋 - this pull request hasn't had any new commits for approximately 5 months. I plan to close this in a month if the pull request doesn't have any new commits by then. In lieu of a stalled pull request, please consider closing this and open an issue instead if a reminder is needed to revisit in the future. Maintainers may also choose to add If this PR still needs to be reviewed, as an author, you can rebase it to reset the clock. If you believe I commented on this pull request incorrectly, please report this here. |
|
@bmorris3 - would you have time to rebase this and implement @taldcroft's comments to get this working? |
|
@astrofrog @bmorris3 - I took a quick crack at fixing this. It looks like |
|
Passing tests locally! @astrofrog please have a look and think about what this might break. |
| TableReplaceWarning, stacklevel=3) | ||
| elif column.dtype.kind in ['f', 'c']: | ||
| out[name] = column.filled(np.nan) | ||
| out[name] = column |
There was a problem hiding this comment.
It turns out this intermediate nan-filled copy is not needed, pandas deals with a MaskedArray subclass just fine.
|
@astrofrog -this needs a quick review, or we can just push to 4.2. |
@taldcroft has now contributed to PR, so approval from different maintainer needed
|
Thanks for carrying this over the finish line, @taldcroft! |
PR astropy#9541 ensured converting a `Table` to a pandas `DataFrame` handles integer columns, including masked columns, much better, but the documentation was not updated until now.
Description
This pull request is to address issue #9280. Adding support for pandas nullable integers in the
Table.to_pandasfunction, as suggested by @mar-ses. We're new to contributing toTable, so we're happy to iterate if generating a pandas table from a combination of masked arrays and a pandasSeriesdoesn't jive with the Table style.Fixes #9280.