-
-
Notifications
You must be signed in to change notification settings - Fork 18.4k
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
Examples for Series ops should be specific to each method. #24589
Comments
It looks to me like this is a larger problem with the https://pandas.pydata.org/pandas-docs/stable/generated/pandas.Series.gt.html In /pandas/core/ops.py it seems the |
I think each method deserves an example. |
Hi @timgeb ! |
Repurposing this for a general "fix all the Series ops examples". It'd be helpful if someone could make a checklist on GitHub with all the Series ops (add, divmod, etc.) that need examples. And we can check them off as we go (one PR per op). |
Hi all, first contributor here Looks like the list of affected cases is here Checklist:
A quick script for comparing Series method docstring content: link |
So my understanding is that we will need to:
|
…lex_doc to inject examples from _op_desc (pandas-dev#24589)
Opened initial PR here, please let me know if this approach makes sense. Do we have any guidelines for writing examples? |
* upstream/master: (110 commits) DOC: hardcode contributors for 0.24.x releases (pandas-dev#25662) DOC: restore toctree maxdepth (pandas-dev#25134) BUG: Redefine IndexOpsMixin.size, fix pandas-dev#25580. (pandas-dev#25584) BUG: to_csv line endings with compression (pandas-dev#25625) DOC: file obj for to_csv must be newline='' (pandas-dev#25624) Suppress incorrect warning in nargsort for timezone-aware DatetimeIndex (pandas-dev#25629) TST: fix incorrect sparse test (now failing on scipy master) (pandas-dev#25653) CLN: Removed debugging code (pandas-dev#25647) DOC: require Return section only if return is not None nor commentary (pandas-dev#25008) DOC:Remove hard-coded examples from _flex_doc_SERIES (pandas-dev#24589) (pandas-dev#25524) TST: xref pandas-dev#25630 (pandas-dev#25643) BUG: Fix pandas-dev#25481 by fixing the error message in TypeError (pandas-dev#25540) Fixturize tests/frame/test_mutate_columns.py (pandas-dev#25642) Fixturize tests/frame/test_join.py (pandas-dev#25639) Fixturize tests/frame/test_combine_concat.py (pandas-dev#25634) Fixturize tests/frame/test_asof.py (pandas-dev#25628) BUG: Fix user-facing AssertionError with to_html (pandas-dev#25608) (pandas-dev#25620) DOC: resolve all GL03 docstring validation errors (pandas-dev#25525) TST: failing wheel building on PY2 and old numpy (pandas-dev#25631) DOC: Remove makePanel from docs (pandas-dev#25609) (pandas-dev#25612) ...
Hi all, first timer here. |
#25524 may give some insight. That did add and sub. pandas/pandas/core/ops/docstrings.py Line 236 in 045880c
df_examples is None need to be updated.
|
I would like to add series examples for "gt", "lt", and "eq" if that is okay. |
adds documentation example to: - `pandas.Series.eq` - `pandas.Series.ne` - `pandas.Series.gt`, - `pandas.Series.ge` - `pandas.series.le` - `pandas.series.lt`
@sullivanbt after #32704, is divmod the only one remaining? |
@TomAugspurger Yes, |
The code example for Series.divmod uses
Series.add
and I'm not sure what this is supposed to convey.In addition, "Equivalent to
series divmod other
" and "See also:Series.None
" look strange to me.The text was updated successfully, but these errors were encountered: