Skip to content

Conversation

@iasoon
Copy link
Contributor

@iasoon iasoon commented May 2, 2022

xref #37715

Copy link
Member

@twoertwein twoertwein left a comment

Choose a reason for hiding this comment

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

Small comment, looks good otherwise!

@iasoon iasoon force-pushed the typing/core-describe branch from 1be8d92 to 60e3879 Compare May 3, 2022 15:33

def format_percentiles(
percentiles: (np.ndarray | list[int | float] | list[float] | list[str | float]),
percentiles: (np.ndarray | Sequence[float]),
Copy link
Member

Choose a reason for hiding this comment

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

Was there a reason why the function was supposed to accept strings? @jreback I don't think it supports str as one of the first lines isnp.isclose(percentiles.astype(int), percentiles) which should fail for str (didn't try it)?

Copy link
Contributor

Choose a reason for hiding this comment

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

don't remember. happy to eliminate it (assume we don't have tests / usage for this)

@twoertwein twoertwein added the Typing type annotations, mypy/pyright type checking label May 6, 2022
@jreback jreback added this to the 1.5 milestone May 6, 2022
@jreback jreback merged commit ddb315f into pandas-dev:main May 6, 2022
@jreback
Copy link
Contributor

jreback commented May 6, 2022

thanks @iasoon

yehoshuadimarsky pushed a commit to yehoshuadimarsky/pandas that referenced this pull request Jul 13, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Typing type annotations, mypy/pyright type checking

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants