-
-
Notifications
You must be signed in to change notification settings - Fork 18.4k
DOC: Cleaned references to pandas <v0.12 in docs #17375
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
DOC: Cleaned references to pandas <v0.12 in docs #17375
Conversation
@topper-123 : I might consider even going to I would leave the |
Codecov Report
@@ Coverage Diff @@
## master #17375 +/- ##
==========================================
- Coverage 91.01% 90.99% -0.03%
==========================================
Files 163 163
Lines 49567 49567
==========================================
- Hits 45113 45103 -10
- Misses 4454 4464 +10
Continue to review full report at Codecov.
|
Codecov Report
@@ Coverage Diff @@
## master #17375 +/- ##
==========================================
+ Coverage 91.01% 91.14% +0.12%
==========================================
Files 163 163
Lines 49567 49581 +14
==========================================
+ Hits 45113 45190 +77
+ Misses 4454 4391 -63
Continue to review full report at Codecov.
|
I like this. I think the cutoff you've chosen here is a good one for now. v0.12 marks a slow-down in the development pace of pandas (just look at the pace of release tags). 0.17.0 may be >3 versions old, but it's also less than two years old. In general I would go by time instead of number of major versions.
I don't understand what this was originally intended to convey. There are at least two types of thread-safety:
Like most Python code, pandas falls in the first category, not the second. This is tested routinely by dask. But not even built-in data structures are thread-safe in the second sense in Python.
I'm pretty sure 0.10.1 references the pandas version. HDF5 is on version 1.8.17. I don't think it's important to mention the version here at this point, since 0.10.1 is quite old. |
this has nothing to do with the HDF5 standard. This is a reference to the pandas version itself. in any event it can be removed. |
doc/source/basics.rst
Outdated
@@ -251,8 +251,8 @@ replace NaN with some other value using ``fillna`` if you wish). | |||
Flexible Comparisons | |||
~~~~~~~~~~~~~~~~~~~~ | |||
|
|||
Starting in v0.8, pandas introduced binary comparison methods eq, ne, lt, gt, | |||
le, and ge to Series and DataFrame whose behavior is analogous to the binary | |||
Note that Series and DataFrame have the binary comparison methods eq, ne, lt, gt, |
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.
remove the 'Note that'
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.
use double-backtics on all of the eq
etc (better readability)
doc/source/dsintro.rst
Outdated
@@ -698,7 +698,7 @@ DataFrame in tabular form, though it won't always fit the console width: | |||
|
|||
print(baseball.iloc[-20:, :12].to_string()) | |||
|
|||
New since 0.10.0, wide DataFrames will now be printed across multiple rows by | |||
Note that wide DataFrames will be printed across multiple rows by |
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.
remove Note that
@@ -856,8 +856,7 @@ DataFrame objects with mixed-type columns, all of the data will get upcasted to | |||
From DataFrame using ``to_panel`` method | |||
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ | |||
|
|||
This method was introduced in v0.7 to replace ``LongPanel.to_long``, and converts | |||
a DataFrame with a two-level index to a Panel. | |||
``to_panel`` converts a DataFrame with a two-level index to a Panel. |
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.
can you add a referencde to the section where panel is deprecated.
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.
There is a deprecation warning a bit above, so it's too much adding it here also IMO. I changed a note that calls on people to contribute to panels, though, as that isnt relevant anymore.
doc/source/groupby.rst
Outdated
@@ -140,7 +140,7 @@ columns: | |||
|
|||
In [5]: grouped = df.groupby(get_letter_type, axis=1) | |||
|
|||
Starting with 0.8, pandas Index objects now support duplicate values. If a | |||
Note that pandas Index objects support duplicate values. If a |
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.
remove the Note that
doc/source/io.rst
Outdated
@@ -3878,7 +3878,7 @@ create a new table!) | |||
Iterator | |||
++++++++ | |||
|
|||
Starting in ``0.11.0``, you can pass, ``iterator=True`` or ``chunksize=number_in_a_chunk`` | |||
Note that you can pass ``iterator=True`` or ``chunksize=number_in_a_chunk`` |
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.
remove Note that
Adjusted according to comments. Wrt. backwards compatabilty of |
doc/source/io.rst
Outdated
|
||
import os | ||
legacy_file_path = os.path.abspath('source/_static/legacy_0.10.h5') | ||
|
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.
actually you can also remove the legacy stuff from the tests as well (and add a small note in the whatsnew)
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.
Ok.
Is it correct we're talking about the tests/io/test_pytables.py::testHDFStore.test_legacy*
functions? (4 tests)
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.
Can we leave test changes for a separate PR please?
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.
I've made a start to it (#17398), but I have some issuse.
One issue is that this doc fragment uses a binary hdf file that needs to be deleted. Can this request be accepted now, so the other will pass? I will do it today and/or tomorrow.
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.
you can remove this part of the doc in the other PR
The removal of the note about backwards compatibilit has been moved to #17404, as those two things are connected through the file IMO this should be ready now to commit. I will look into cleaning references upto v0.14 or v0.15 as the next step. |
doc/source/missing_data.rst
Outdated
considered to be "NA" in computations. This is no longer the case by | ||
default; use the ``mode.use_inf_as_na`` option to recover it. | ||
If you want to consider ``inf`` and ``-inf`` | ||
to be "NA" in computations, you can use the ``mode.use_inf_as_na`` option to archieve it. |
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.
achieve
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.
tiny typo. ping on green.
Ping, corrected. |
@topper-123 Thanks a lot, this was a good idea! |
There is a lot of references to in the docs to when exactly some change occured. For newer changes this is great, but there comes a time when such references only disturb the reader rather than help him, as the versions referenced become so old, that they become noise rather than help.
I've cleaned up references up to and including v0.11.
IMO I could have gone higher (v.015?), but can do that in some later round.
Some issues I would be glad for input on:
gotschas.rst
, there is a sentence "As of pandas 0.11, pandas is not 100% thread safe." I haven't altered this, but I presume this still is correct in the newest version of pandas? Then IMO it should be changed to reference a newer version or simply to "pandas is currently not 100% thread safe."io.rst
there is a sentence "0.10.1 ofHDFStore
can read tables created in a prior version of pandas, ...". I'm not even sure the "0.10.1" references the version of pandas or a HDF library and I left it alone. The paragraph also discusses backwards compatability, which makes it somewhat relevant to keep around, even if it's an old change.