Skip to content

Conversation

andrewgsavage
Copy link

This adds an is_unambiguous_scalar (as suggested) method to ExtensionDtype that can be used to infer the dtype when it isn't passed into Series or DataFrame constructors.

With these changes Series() can recognise pint.Quantitys and construct a PintArray. Is this a good approch? I've not done any inference in sanitize_array as its docstring doesn't mention inference. However it looks like it'd be easier to do so in there than do so in the various constructor methods.

Copy link
Contributor

This pull request is stale because it has been open for thirty days with no activity. Please update and respond to this comment if you're still interested in working on this.

@github-actions github-actions bot added the Stale label Oct 10, 2024
@mroeschke
Copy link
Member

Thanks for the pull request, but it appears to have gone stale. If interested in continuing, please merge in the main branch, address any review comments and/or failing tests, and we can reopen.

@mroeschke mroeschke closed this Oct 29, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

ENH: Specify how pandas infers dtype on objects

2 participants