-
-
Notifications
You must be signed in to change notification settings - Fork 18.5k
DOC: clean io.rst codeblocks for PEP8 #20632
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
Conversation
Codecov Report
@@ Coverage Diff @@
## master #20632 +/- ##
==========================================
+ Coverage 91.83% 91.84% +0.01%
==========================================
Files 153 153
Lines 49269 49256 -13
==========================================
- Hits 45247 45241 -6
+ Misses 4022 4015 -7
Continue to review full report at Codecov.
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks, this is very welcome. Added a minor comment
doc/source/io.rst
Outdated
@@ -921,7 +921,7 @@ Note that performance-wise, you should try these methods of parsing dates in ord | |||
1. Try to infer the format using ``infer_datetime_format=True`` (see section below). | |||
|
|||
2. If you know the format, use ``pd.to_datetime()``: | |||
``date_parser=lambda x: pd.to_datetime(x, format=...)``. | |||
``date_parser = lambda x: pd.to_datetime(x, format=...)``. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This one is not necessarily correct, as date_parser
is a keyword, and for keywords in function calls no spaces ...
doc/source/io.rst
Outdated
index=pd.date_range('20000101', periods=1000)) | ||
store.append('df_coord', df_coord) | ||
c = store.select_as_coordinates('df_coord', 'index > 20020101') | ||
c |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
this change of c.summary() to c was on purpose? (not familiar with HDFStore)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
.summary() was recently deprecate so this is ok
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ah, the return value is an index, not HFDStore, OK +1
thanks @pulkitmaloo (fixed a few typos) |
Thanks for fixing the typos and accepting the PR. |
Checklist for the pandas documentation sprint (ignore this if you are doing
an unrelated PR):
scripts/validate_docstrings.py <your-function-or-method>
git diff upstream/master -u -- "*.py" | flake8 --diff
python doc/make.py --single <your-function-or-method>
Please include the output of the validation script below between the "```" ticks:
If the validation script still gives errors, but you think there is a good reason
to deviate in this case (and there are certainly such cases), please state this
explicitly.
Checklist for other PRs (remove this part if you are doing a PR for the pandas documentation sprint):
git diff upstream/master -u -- "*.py" | flake8 --diff