pandas-dev / pandas

Flexible and powerful data analysis / manipulation library for Python, providing labeled data structures similar to R data.frame objects, statistical functions, and much more
https://pandas.pydata.org
BSD 3-Clause "New" or "Revised" License
43.83k stars 18k forks source link

DOC: Fix docstring validation errors for pandas.core.groupby #60365

Open jmalp opened 2 days ago

jmalp commented 2 days ago

Parent Issue: #58063 pandas has a script for validating docstrings:

https://github.com/pandas-dev/pandas/blob/6a7685faf104f8582e0e75f1fae58e09ae97e2fe/ci/code_checks.sh#L92-L105

Currently, some methods fail docstring validation check. The task is:

  1. Take 1-5 methods
  2. Run: scripts/validate_docstrings.py

Example command:

scripts/validate_docstrings.py pandas.core.groupby.DataFrameGroupBy.get_group

Example output:

################################################################################
################################## Validation ##################################
################################################################################

3 Errors found for `pandas.core.groupby.DataFrameGroupBy.get_group`:
        ES01    No extended summary found
        RT03    Return value has no description
        SA01    See Also section not found
  1. Check if validation docstrings passes for those methods, and if it’s necessary fix the docstrings according to whatever error is reported. Note: Ignore ES01 errors, these are not required to be fixed.

  2. Remove those methods from 'code_checks.sh' if all errors are cleared and the docstring is correct, otherwise, remove the specific error that was fixed from the list of errors for that method.

  3. Commit, push, open pull request

Please don't comment take as multiple people can work on this issue. Just comment on which methods you are going to work on.

If you're new contributor, please check the contributing guide

srjsunny commented 2 days ago

I'm working on these=>

-i "pandas.core.groupby.DataFrameGroupBy.boxplot PR07,RT03,SA01" \ 
 -i "pandas.core.groupby.DataFrameGroupBy.get_group RT03,SA01" \ 
 -i "pandas.core.groupby.DataFrameGroupBy.indices SA01" \ 
ensalada-de-pechuga commented 2 days ago

working on:

 -i "pandas.core.groupby.SeriesGroupBy.is_monotonic_decreasing SA01" \ 
 -i "pandas.core.groupby.SeriesGroupBy.is_monotonic_increasing SA01" \ 
 -i "pandas.core.groupby.SeriesGroupBy.nth PR02" \ 
 -i "pandas.core.groupby.DataFrameGroupBy.nth PR02" \ 
gvmmybear commented 1 day ago

I will work on:

 -i "pandas.core.groupby.SeriesGroupBy.indices SA01" \ 
 -i "pandas.core.groupby.SeriesGroupBy.plot PR02" \ 
thedataninja1786 commented 1 day ago

I will work on:

 -i "pandas.core.groupby.DataFrameGroupBy.sem SA01" \ 
 -i "pandas.core.groupby.DataFrameGroupBy.nunique SA01" \