BrandonFors/pandas-github-issues huggingface dataset:
DOC: update the Series.sort_values docstring
State: closed

Checklist for the pandas documentation sprint (ignore this if you are doing
an unrelated PR):

- [x] PR title is "DOC: update the <your-function-or-method> docstring"
- [x] The validation script passes: `scripts/validate_docstrings.py <your-function-or-method>`
- [ ] The PEP8 style check passes: `git diff upstream/master -u -- "*.py" | flake8 --diff`
- [x] The html version looks good: `python doc/make.py --single <your-function-or-method>`
- [ ] It has been proofread on language by another sprint participant

Please include the output of the validation script below between the "```" ticks:

```
# paste output of "scripts/validate_docstrings.py <your-function-or-method>" here
# between the "```" (remove this comment, but keep the "```")

```

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):

- [ ] closes #xxxx
- [ ] tests added / passed
- [ ] passes `git diff upstream/master -u -- "*.py" | flake8 --diff`
- [ ] whatsnew entry


Labels:
name: Duplicate Report
description: Duplicate issue or pull request

Comments:
Hello @rafarui! Thanks for submitting the PR.

 - In the file [`pandas/core/series.py`](https://github.com/pandas-dev/pandas/blob/04c8faadee25d631ffd75302ac022d73ff2d66a3/pandas/core/series.py), following are the PEP8 issues :

> [Line 1888:5](https://github.com/pandas-dev/pandas/blob/04c8faadee25d631ffd75302ac022d73ff2d66a3/pandas/core/series.py#L1888): [E265](https://duckduckgo.com/?q=pep8%20E265) block comment should start with '# '
> [Line 1894:80](https://github.com/pandas-dev/pandas/blob/04c8faadee25d631ffd75302ac022d73ff2d66a3/pandas/core/series.py#L1894): [E501](https://duckduckgo.com/?q=pep8%20E501) line too long (86 > 79 characters)
> [Line 1905:80](https://github.com/pandas-dev/pandas/blob/04c8faadee25d631ffd75302ac022d73ff2d66a3/pandas/core/series.py#L1905): [E501](https://duckduckgo.com/?q=pep8%20E501) line too long (123 > 79 characters)
> [Line 1908:80](https://github.com/pandas-dev/pandas/blob/04c8faadee25d631ffd75302ac022d73ff2d66a3/pandas/core/series.py#L1908): [E501](https://duckduckgo.com/?q=pep8%20E501) line too long (86 > 79 characters)
> [Line 1923:80](https://github.com/pandas-dev/pandas/blob/04c8faadee25d631ffd75302ac022d73ff2d66a3/pandas/core/series.py#L1923): [E501](https://duckduckgo.com/?q=pep8%20E501) line too long (83 > 79 characters)


@rafarui do you wish to continue working on this?  Sorry we didn't have a chance to review it yesterdya, but if you reopen I'll take a look.
@TomAugspurger 
No need, I had opened this pull request by mistake. The "right"one is this one
https://github.com/pandas-dev/pandas/pull/20247

Thanks
DOC: update the pd.Index.contains docstring
State: closed

Checklist for the pandas documentation sprint (ignore this if you are doing
an unrelated PR):

- [X] PR title is "DOC: update the <your-function-or-method> docstring"
- [ ] The validation script passes: `scripts/validate_docstrings.py <your-function-or-method>`
- [X] The PEP8 style check passes: `git diff upstream/master -u -- "*.py" | flake8 --diff`
- [X] The html version looks good: `python doc/make.py --single <your-function-or-method>`
- [X] It has been proofread on language by another sprint participant

Please include the output of the validation script below between the "```" ticks:

```

################################################################################
###################### Docstring (pandas.Index.contains)  ######################
################################################################################

Return a boolean if key is in the index.

This function returns True if key is in the index and
returns False if key is not in index.

Parameters
----------
key : immutable object
    Key to be searched.

Returns
-------
bool
    Result of the key search.

Notes
-----
    CategoricalIndex is a sub-class of Index.

Examples
--------
>>> pd.CategoricalIndex([2000, 2001, 2012]).contains(2001)
True
>>> pd.CategoricalIndex([2000, 2001, 2012]).contains(2222)
False

################################################################################
################################## Validation ##################################
################################################################################

Errors found:
        See Also section not found
```

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.

See Also missing because we haven't found similar functions

Checklist for other PRs (remove this part if you are doing a PR for the pandas documentation sprint):

- [ ] closes #xxxx
- [ ] tests added / passed
- [ ] passes `git diff upstream/master -u -- "*.py" | flake8 --diff`
- [ ] whatsnew entry


Labels:
name: Docs
name: Indexing
description: Related to indexing on series/frames, not to indexes themselves

Comments:
@dajcs do you have time to update the PR based on the feedback?
I am working to update this PR in accordance with the reviews made to it and match it to the Pandas docstring standards.
Superseded by #23100 and #23107
DOC: update the pandas.api.types.is_list_like
State: closed

Checklist for the pandas documentation sprint (ignore this if you are doing
an unrelated PR):

- [X] PR title is "DOC: update the <your-function-or-method> docstring"
- [X] The validation script passes: `scripts/validate_docstrings.py <your-function-or-method>`
- [X] The PEP8 style check passes: `git diff upstream/master -u -- "*.py" | flake8 --diff`
- [X] The html version looks good: `python doc/make.py --single <your-function-or-method>`
- [X] It has been proofread on language by another sprint participant

Please include the output of the validation script below between the "```" ticks:

```
Docstring for "pandas.core.dtypes.inference.is_list_like" correct. :)

```

Labels:
name: Docs
name: Dtype Conversions
description: Unexpected or buggy dtype conversions

Comments:
# [Codecov](https://codecov.io/gh/pandas-dev/pandas/pull/20207?src=pr&el=h1) Report
> :exclamation: No coverage uploaded for pull request base (`master@8c77238`). [Click here to learn what that means](https://docs.codecov.io/docs/error-reference#section-missing-base-commit).
> The diff coverage is `n/a`.

[![Impacted file tree graph](https://codecov.io/gh/pandas-dev/pandas/pull/20207/graphs/tree.svg?token=eZ4WkYLtcO&src=pr&width=650&height=150)](https://codecov.io/gh/pandas-dev/pandas/pull/20207?src=pr&el=tree)

```diff
@@            Coverage Diff            @@
##             master   #20207   +/-   ##
=========================================
  Coverage          ?    91.7%           
=========================================
  Files             ?      150           
  Lines             ?    49152           
  Branches          ?        0           
=========================================
  Hits              ?    45074           
  Misses            ?     4078           
  Partials          ?        0
```

| Flag | Coverage Δ | |
|---|---|---|
| #multiple | `90.08% <ø> (?)` | |
| #single | `41.84% <ø> (?)` | |

| [Impacted Files](https://codecov.io/gh/pandas-dev/pandas/pull/20207?src=pr&el=tree) | Coverage Δ | |
|---|---|---|
| [pandas/core/dtypes/inference.py](https://codecov.io/gh/pandas-dev/pandas/pull/20207/diff?src=pr&el=tree#diff-cGFuZGFzL2NvcmUvZHR5cGVzL2luZmVyZW5jZS5weQ==) | `98.41% <ø> (ø)` | |

------

[Continue to review full report at Codecov](https://codecov.io/gh/pandas-dev/pandas/pull/20207?src=pr&el=continue).
> **Legend** - [Click here to learn more](https://docs.codecov.io/docs/codecov-delta)
> `Δ = absolute <relative> (impact)`, `ø = not affected`, `? = missing data`
> Powered by [Codecov](https://codecov.io/gh/pandas-dev/pandas/pull/20207?src=pr&el=footer). Last update [8c77238...dfb5f09](https://codecov.io/gh/pandas-dev/pandas/pull/20207?src=pr&el=lastupdated). Read the [comment docs](https://docs.codecov.io/docs/pull-request-comments).
DOC: update the DataFrame.head()  docstring
State: closed

- Improved summary details
- Added description of last in see-also

Checklist for the pandas documentation sprint (ignore this if you are doing
an unrelated PR):

- [X] PR title is "DOC: update the <your-function-or-method> docstring"
- [X] The validation script passes: `scripts/validate_docstrings.py <your-function-or-method>`
- [X] The PEP8 style check passes: `git diff upstream/master -u -- "*.py" | flake8 --diff`
- [X] The html version looks good: `python doc/make.py --single <your-function-or-method>`
- [X] It has been proofread on language by another sprint participant

Please include the output of the validation script below between the "```" ticks:

```

################################################################################
###################### Docstring (pandas.DataFrame.head)  ######################
################################################################################

Return the first n rows.

This function returns rows for the object based on the underlying
index. It is useful for quickly testing if your object has the
right type of data in it.

Parameters
----------
n : int, default 5
    Number of rows to select.

Returns
-------
obj_head : type of caller
    The first n rows of the caller object.

See Also
--------
pandas.DataFrame.tail
    Returns the last n rows.

Examples
--------
>>> df = pd.DataFrame({'animal':['alligator', 'bee', 'falcon', 'lion',
...                    'monkey', 'parrot', 'shark', 'whale', 'zebra']})
>>> df
      animal
0  alligator
1        bee
2     falcon
3       lion
4     monkey
5     parrot
6      shark
7      whale
8      zebra

Viewing the first 5 lines

>>> df.head()
      animal
0  alligator
1        bee
2     falcon
3       lion
4     monkey

Viewing the first n lines (three in this case)

>>> df.head(3)
      animal
0  alligator
1        bee
2     falcon

################################################################################
################################## Validation ##################################
################################################################################

Docstring for "pandas.DataFrame.head" correct. :)
```

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.

Labels:

Comments:
Thanks!
DOC: update the docstring of pandas.DataFrame.from_dict
State: closed

```
################################################################################
#################### Docstring (pandas.DataFrame.from_dict) ####################
################################################################################

Construct DataFrame from dict of array-like or dicts.

Creates DataFrame object from dictionary by columns or by index
allowing dtype specification.

Parameters
----------
data : dict
    Of the form {field : array-like} or {field : dict}.
orient : {'columns', 'index'}, default 'columns'
    The "orientation" of the data. If the keys of the passed dict
    should be the columns of the resulting DataFrame, pass 'columns'
    (default). Otherwise if the keys should be rows, pass 'index'.
dtype : dtype, default None
    Data type to force, otherwise infer.
columns : list, default None
    Column labels to use when orient='index'. Raises a ValueError
    if used with orient='columns'
    .. versionadded:: 0.23.0.

See Also
--------
DataFrame.from_records : Create DataFrame from ndarray (structured dtype),
                         list of tuples, dict, or DataFrame
DataFrame.from_items : Create DataFrame from sequence of (key, value) pairs.

Returns
-------
DataFrame

Examples
--------
>>> data = {'col_1': [3, 2, 1, 0], 'col_2': ['a', 'b', 'c', 'd']}
>>> data
{'col_1': [3, 2, 1, 0], 'col_2': ['a', 'b', 'c', 'd']}

>>> pd.DataFrame.from_dict(data)
   col_1 col_2
0      3     a
1      2     b
2      1     c
3      0     d

>>> pd.DataFrame.from_dict(data, orient='index')
       0  1  2  3
col_1  3  2  1  0
col_2  a  b  c  d

################################################################################
################################## Validation ##################################
################################################################################

Docstring for "pandas.DataFrame.from_dict" correct. :)
```

Labels:
name: Docs
name: Reshaping
description: Concat, Merge/Join, Stack/Unstack, Explode

Comments:
Hello @ReubenMarkham! Thanks for updating the PR.





Cheers ! There are no PEP8 issues in this Pull Request. :beers: 

##### Comment last updated on March 10, 2018 at 17:29 Hours UTC
@ReubenMarkham do want to continue working on this?
DOC: update the CategoricalIndex docstring
State: closed

Checklist for the pandas documentation sprint (ignore this if you are doing
an unrelated PR):

- [X] PR title is "DOC: update the <your-function-or-method> docstring"
- [X] The validation script passes: `scripts/validate_docstrings.py <your-function-or-method>`
- [X] The PEP8 style check passes: `git diff upstream/master -u -- "*.py" | flake8 --diff`
- [X] The html version looks good: `python doc/make.py --single <your-function-or-method>`
- [X] It has been proofread on language by another sprint participant

Please include the output of the validation script below between the "```" ticks:

```
################################################################################
################################## Validation ##################################
################################################################################

Errors found:
        No returns section found
        No examples section found
```

The documentation has been improved. The function actually refers to a function defined elsewhere. Therefore, we decided to include a "see also" section. 

Same message for CategoricalIndex.codes, CategoricalIndex.ordered and CategoricalIndex.categories.


Labels:
name: Docs
name: Categorical
description: Categorical Data Type

Comments:
Hello @Adrienlq! Thanks for updating the PR.

 - In the file [`pandas/core/indexes/category.py`](https://github.com/pandas-dev/pandas/blob/e38c4d4063cbece61fb8989515f9416240bb5778/pandas/core/indexes/category.py), following are the PEP8 issues :

> [Line 386:80](https://github.com/pandas-dev/pandas/blob/e38c4d4063cbece61fb8989515f9416240bb5778/pandas/core/indexes/category.py#L386): [E501](https://duckduckgo.com/?q=pep8%20E501) line too long (82 > 79 characters)



##### Comment last updated on March 12, 2018 at 09:05 Hours UTC
@Adrienlq any reason you are closing this?
Hello, sorry I have very few experience with github. I thought the PR was a failure so I closed it.
What is the status of the PR ? Should I do something now ?
Thank you
@Adrienlq The PR is certainly not a failure! It's a good start, but with some to do's. I added comments about that, and if you would like to further work on it, you can make changes based on this feedback, add this as a commit in your branch, and push this to github, which will automatically update this PR. 

See https://python-sprints.github.io/pandas/guide/pandas_pr.html#updating-a-pull-request for some more detailed information
closing as stale. if you'd like to continue pls ping.
DOC: update the api.types.is_number docstring
State: closed

Checklist for the pandas documentation sprint (ignore this if you are doing
an unrelated PR):

- [X] PR title is "DOC: update the <your-function-or-method> docstring"
- [X] The validation script passes: `scripts/validate_docstrings.py <your-function-or-method>`
- [X] The PEP8 style check passes: `git diff upstream/master -u -- "*.py" | flake8 --diff`
- [X] The html version looks good: `python doc/make.py --single <your-function-or-method>`
- [X] It has been proofread on language by another sprint participant

Please include the output of the validation script below between the "```" ticks:

```
Docstring for "pandas.core.dtypes.inference.is_number" correct. :)
```


Labels:
name: Docs
name: Dtype Conversions
description: Unexpected or buggy dtype conversions

Comments:
# [Codecov](https://codecov.io/gh/pandas-dev/pandas/pull/20196?src=pr&el=h1) Report
> :exclamation: No coverage uploaded for pull request base (`master@afa6c42`). [Click here to learn what that means](https://docs.codecov.io/docs/error-reference#section-missing-base-commit).
> The diff coverage is `n/a`.

[![Impacted file tree graph](https://codecov.io/gh/pandas-dev/pandas/pull/20196/graphs/tree.svg?token=eZ4WkYLtcO&width=650&height=150&src=pr)](https://codecov.io/gh/pandas-dev/pandas/pull/20196?src=pr&el=tree)

```diff
@@            Coverage Diff            @@
##             master   #20196   +/-   ##
=========================================
  Coverage          ?   91.72%           
=========================================
  Files             ?      150           
  Lines             ?    49152           
  Branches          ?        0           
=========================================
  Hits              ?    45086           
  Misses            ?     4066           
  Partials          ?        0
```

| Flag | Coverage Δ | |
|---|---|---|
| #multiple | `90.11% <ø> (?)` | |
| #single | `41.84% <ø> (?)` | |

| [Impacted Files](https://codecov.io/gh/pandas-dev/pandas/pull/20196?src=pr&el=tree) | Coverage Δ | |
|---|---|---|
| [pandas/core/dtypes/inference.py](https://codecov.io/gh/pandas-dev/pandas/pull/20196/diff?src=pr&el=tree#diff-cGFuZGFzL2NvcmUvZHR5cGVzL2luZmVyZW5jZS5weQ==) | `98.41% <ø> (ø)` | |

------

[Continue to review full report at Codecov](https://codecov.io/gh/pandas-dev/pandas/pull/20196?src=pr&el=continue).
> **Legend** - [Click here to learn more](https://docs.codecov.io/docs/codecov-delta)
> `Δ = absolute <relative> (impact)`, `ø = not affected`, `? = missing data`
> Powered by [Codecov](https://codecov.io/gh/pandas-dev/pandas/pull/20196?src=pr&el=footer). Last update [afa6c42...0aa91ba](https://codecov.io/gh/pandas-dev/pandas/pull/20196?src=pr&el=lastupdated). Read the [comment docs](https://docs.codecov.io/docs/pull-request-comments).

@jreback, changes done :)
DOC: update the Series.dt.strftime docstring
State: closed

Checklist for the pandas documentation sprint (ignore this if you are doing
an unrelated PR):

- [x] PR title is "DOC: update the <your-function-or-method> docstring"
- [ ] The validation script passes: `scripts/validate_docstrings.py <your-function-or-method>`
- [x] The PEP8 style check passes: `git diff upstream/master -u -- "*.py" | flake8 --diff`
- [x] The html version looks good: `python doc/make.py --single <your-function-or-method>`
- [x] It has been proofread on language by another sprint participant

Please include the output of the validation script below between the "```" ticks:

```
################################################################################
#################### Docstring (pandas.Series.dt.strftime)  ####################
################################################################################

Format series values with a date format string.

This function formats series values as specified by `date_format`, which
supports the same string format as the python standard library. Details
of the string format can be found in `python string format doc <https://docs.python.org/3/library/datetime.html#strftime-and-strptime-behavior>`__.

Parameters
----------
date_format : str
    Date format string (e.g. "%Y-%m-%d").

Returns
-------
ndarray of formatted strings

Examples
--------
>>> rng = pd.date_range('10/3/2018 16:20:10', periods=2, freq='H')
>>> rng.strftime("%Y-%m-%d")
array(['2018-10-03', '2018-10-03'], dtype='<U10')

################################################################################
################################## Validation ##################################
################################################################################

Errors found:
        Errors in parameters section
                Parameters {'kwargs', 'args'} not documented
                Unknown parameters {'date_format'}
        See Also section not found
```

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.

The method is injected with `_add_delegate_accessors` and the resulting signature on the object has `*args` and `**kwargs` instead of the actual `date_format`


Labels:
name: Docs
name: Datetime
description: Datetime data dtype

Comments:
this is a duplicate of #20103 pls coordinate
Closed because of duplication
DOC: Improved the docstring of pandas.Series.clip
State: closed

```
################################################################################
######################## Docstring (pandas.Series.clip) ########################
################################################################################

Trim values at input threshold(s).

    Truncates values below and above specified thresholds.
    Thresholds can be singular values or array like, and in
the latter case the truncation is performed element-wise
in the specified axis.

Parameters
----------
lower : float or array_like, default None
    Minimum threshold value. All values below this
    threshold will be set to it.
upper : float or array_like, default None
    Maximum threshold value. All values above this 
    threshold will be set to it.
axis : int or string axis name, optional
    Align object with lower and upper along the given axis.
inplace : boolean, default False
    Whether to perform the operation in place on the data
        .. versionadded:: 0.21.0.
args : iterable, optional
    Arguments to pass to the function.
kwargs : mapping, optional
    Keyworded arguments to pass to the function.

See Also
--------
clip_lower : Return copy of the input with values below given value(s) truncated.
clip_upper : Return copy of the input with values above given value(s) truncated.

Returns
-------
clipped : Series

Examples
--------
>>> data = {'0': [9, -3, 0, -1, 5], '1': [-2, -7, 6, 8, -5]}
>>> df = pd.DataFrame(data)
>>> df
        0       1
0       9       -2
1       -3      -7
2       0       6
3       -1      8
4       5       -5

>>> df.clip(-4, 6)
    0   1
0       6       -2
1       -3      -4
2       0       6
3       -1      6
4       5       -4

>>> t = pd.Series([2, -4, -1, 6, 3])
>>> t
0    2
1   -4
2   -1
3    6
4    3
dtype: int64

>>> df.clip(t, t + 4, axis=0)
        0       1
0       6       2
1       -3      -4
2       0       3
3       6       8
4       5       3

################################################################################
################################## Validation ##################################
################################################################################

Docstring for "pandas.Series.clip" correct. :)
```


Labels:

Comments:
Hello @ReubenMarkham! Thanks for updating the PR.



Cheers ! There are no PEP8 issues in this Pull Request. :beers: 

##### Comment last updated on March 10, 2018 at 16:27 Hours UTC
@ReubenMarkham why this branch is closed instead of merged?
@stijnvanhoey Hi!, you can find the PR related to this method here: https://github.com/pandas-dev/pandas/pull/20256

Reuben asked me to continue his job and all your suggestions should be already included in the new PR.
Great! Would have been a pity to not include the work of Reuben. Nice work!