DOC: Fix copy-pasted name in `.day_name` docstring
State: closed

Just a small change... Feel free to close and include this change in any other typo-fixing commit if you like. :blush:

Labels:
name: Docs

Comments:
You can simply remove `day_names` and `month_names` from the docstrings since they don't reference any variable that actually exists. It's OK for a returns to simply describe the type of object being returned.

See https://python-sprints.github.io/pandas/guide/pandas_docstring.html#section-4-returns-or-yields
@WillAyd Actually, I prefer it that way, did not know it was allowed in Pandas documentation. :innocent: 

Changed it and force-pushed the commit.
Do these pass the validate_docstring script? I think there is at least a missing period at the end of the descriptions that we should probably just clean up while touching. Maybe a couple more
# [Codecov](https://codecov.io/gh/pandas-dev/pandas/pull/22544?src=pr&el=h1) Report
> Merging [#22544](https://codecov.io/gh/pandas-dev/pandas/pull/22544?src=pr&el=desc) into [master](https://codecov.io/gh/pandas-dev/pandas/commit/3285bdc8e6e1b05d84b6cebea66fdd80fbb84400?src=pr&el=desc) will **decrease** coverage by `<.01%`.
> The diff coverage is `n/a`.

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

```diff
@@            Coverage Diff             @@
##           master   #22544      +/-   ##
==========================================
- Coverage   92.04%   92.04%   -0.01%     
==========================================
  Files         169      169              
  Lines       50787    50787              
==========================================
- Hits        46746    46745       -1     
- Misses       4041     4042       +1
```

| Flag | Coverage Δ | |
|---|---|---|
| #multiple | `90.45% <ø> (-0.01%)` | :arrow_down: |
| #single | `42.29% <ø> (ø)` | :arrow_up: |

| [Impacted Files](https://codecov.io/gh/pandas-dev/pandas/pull/22544?src=pr&el=tree) | Coverage Δ | |
|---|---|---|
| [pandas/core/arrays/datetimes.py](https://codecov.io/gh/pandas-dev/pandas/pull/22544/diff?src=pr&el=tree#diff-cGFuZGFzL2NvcmUvYXJyYXlzL2RhdGV0aW1lcy5weQ==) | `95.52% <ø> (ø)` | :arrow_up: |
| [pandas/util/\_depr\_module.py](https://codecov.io/gh/pandas-dev/pandas/pull/22544/diff?src=pr&el=tree#diff-cGFuZGFzL3V0aWwvX2RlcHJfbW9kdWxlLnB5) | `65.11% <0%> (-2.33%)` | :arrow_down: |
| [pandas/core/strings.py](https://codecov.io/gh/pandas-dev/pandas/pull/22544/diff?src=pr&el=tree#diff-cGFuZGFzL2NvcmUvc3RyaW5ncy5weQ==) | `98.63% <0%> (ø)` | :arrow_up: |
| [pandas/core/indexes/multi.py](https://codecov.io/gh/pandas-dev/pandas/pull/22544/diff?src=pr&el=tree#diff-cGFuZGFzL2NvcmUvaW5kZXhlcy9tdWx0aS5weQ==) | `95.41% <0%> (ø)` | :arrow_up: |
| [pandas/core/frame.py](https://codecov.io/gh/pandas-dev/pandas/pull/22544/diff?src=pr&el=tree#diff-cGFuZGFzL2NvcmUvZnJhbWUucHk=) | `97.2% <0%> (ø)` | :arrow_up: |
| [pandas/util/testing.py](https://codecov.io/gh/pandas-dev/pandas/pull/22544/diff?src=pr&el=tree#diff-cGFuZGFzL3V0aWwvdGVzdGluZy5weQ==) | `85.75% <0%> (ø)` | :arrow_up: |
| [pandas/core/indexes/base.py](https://codecov.io/gh/pandas-dev/pandas/pull/22544/diff?src=pr&el=tree#diff-cGFuZGFzL2NvcmUvaW5kZXhlcy9iYXNlLnB5) | `96.45% <0%> (ø)` | :arrow_up: |
| [pandas/core/resample.py](https://codecov.io/gh/pandas-dev/pandas/pull/22544/diff?src=pr&el=tree#diff-cGFuZGFzL2NvcmUvcmVzYW1wbGUucHk=) | `96.13% <0%> (ø)` | :arrow_up: |

------

[Continue to review full report at Codecov](https://codecov.io/gh/pandas-dev/pandas/pull/22544?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/22544?src=pr&el=footer). Last update [3285bdc...1216484](https://codecov.io/gh/pandas-dev/pandas/pull/22544?src=pr&el=lastupdated). Read the [comment docs](https://docs.codecov.io/docs/pull-request-comments).

Thanks all for your feedback. Updated the docstrings with some of the @datapythonista suggestions (did not add any examples though).

I was unable to run `validate_docstrings.py` (got a `ModuleNotFoundError: No module named 'pandas._libs.window'` exception). :confused: Did not spend much time trying to fix it, I must admit.

As a side note, did you ever think about releasing that docstring checker as a separate package? I bet many other projects could benefit from it. :blush:
Looks like you need to build the C extensions

```sh
python setup.py build_ext --inplace -j 4
```

Not aware of a conversation to have as a separate package but @gfyoung might have some thoughts on that as well
@WillAyd Yeah, that failed too with an error, that's when I stopped trying. :joy: I think I just missed the C++ compiler. May try again later...
@WillAyd Yeah, I was only missing a C++ compiler.

Validated the docstrings. No errors found. :+1:
I uploaded some changes to better match the preferred style and add simple examples (this time I read the style guide :innocent:).

PS: [in the style guide that you shared with me](https://python-sprints.github.io/pandas/guide/pandas_docstring.html), the first example is missing dots after descriptions. That may be misleading for the lazy (like me) that only read the first example and "infer" the rules. :stuck_out_tongue_winking_eye: 
Hello @Peque! Thanks for updating the PR.

 - There are no PEP8 issues in the file [`pandas/core/arrays/datetimes.py`](https://github.com/Peque/pandas/blob/1216484685f6b29f479be59ad9ea4d078149a17b/pandas/core/arrays/datetimes.py) !


@datapythonista Updated the PR showing the `idx` values and using a different `start`.
thanks @Peque