Skip to content
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

[WIP] Convert object dtype #58

Merged
merged 16 commits into from
Jun 25, 2023
Merged

Conversation

andrewgsavage
Copy link
Collaborator

Addresses #55

@andrewgsavage
Copy link
Collaborator Author

readu for review

CHANGES Outdated
@@ -6,6 +6,7 @@ pint-pandas Changelog

- Support for <NA> values in columns with integer magnitudes
- Support for magnitudes of any type, such as complex128 or tuples #146
- A DataFrame/Series.pint.convert_object_dtype() function has been added to create PintArrays from Series of quantitys.
Copy link
Collaborator

Choose a reason for hiding this comment

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

typo: quantitys to quantities

@staticmethod
def _is_object_dtype_and_quantity(obj):
return obj.dtype == "object" and all(
[(isinstance(item, _Quantity) or pd.isna(item)) for item in obj.values]
Copy link
Collaborator

Choose a reason for hiding this comment

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

Does this play well with uncertainties?

@andrewgsavage
Copy link
Collaborator Author

bors r+

@bors
Copy link
Contributor

bors bot commented Jun 25, 2023

Build succeeded!

The publicly hosted instance of bors-ng is deprecated and will go away soon.

If you want to self-host your own instance, instructions are here.
For more help, visit the forum.

If you want to switch to GitHub's built-in merge queue, visit their help page.

@bors bors bot merged commit bf84e37 into hgrecco:master Jun 25, 2023
@andrewgsavage andrewgsavage deleted the convert_object_dtype branch June 26, 2023 20:51
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.

2 participants