Skip to content

CLN: f-string in pandas/core/window/* #29952

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 10 commits into from
Dec 2, 2019

Conversation

ganevgv
Copy link
Contributor

@ganevgv ganevgv commented Dec 2, 2019

ref #29547

  • tests added / passed
  • passes black pandas
  • passes git diff upstream/master -u -- "*.py" | flake8 --diff
  • whatsnew entry

@jreback jreback added the Code Style Code style, linting, code_checks label Dec 2, 2019
@jreback jreback added this to the 1.0 milestone Dec 2, 2019
@ganevgv ganevgv force-pushed the clean/f_string_core_window branch from b023181 to 80f9c1b Compare December 2, 2019 13:49
@ganevgv
Copy link
Contributor Author

ganevgv commented Dec 2, 2019

finally ready for review

@@ -209,10 +209,10 @@ def skew(self, **kwargs):

>>> arr = [1, 2, 3, 4, 999]
>>> import scipy.stats
>>> fmt = "{0:.6f}" # limit the printed precision to 6 digits
>>> print(fmt.format(scipy.stats.kurtosis(arr[:-1], bias=False)))
>>> precision = 6 # limit the printed precision to 6 digits
Copy link
Member

Choose a reason for hiding this comment

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

Minor but I find this rather distracting from the code sample. Can you just hard-code the format specifier in the print statements below?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Sounds good - just did that.

Copy link
Member

@WillAyd WillAyd left a comment

Choose a reason for hiding this comment

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

lgtm

@jreback jreback merged commit 0ffee8b into pandas-dev:master Dec 2, 2019
@jreback
Copy link
Contributor

jreback commented Dec 2, 2019

thanks @ganevgv

proost pushed a commit to proost/pandas that referenced this pull request Dec 19, 2019
proost pushed a commit to proost/pandas that referenced this pull request Dec 19, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Code Style Code style, linting, code_checks
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants