Skip to content

Commit

Permalink
DOC: Fix SA01 errors for DatetimeIndex.month and DatetimeIndex.year (#…
Browse files Browse the repository at this point in the history
…58326)

* Fixing doc string for DatetimeIndex.month and DatetimeIndex.year

* fixing at pandas.Series code_checks
  • Loading branch information
KeiOshima authored Apr 19, 2024
1 parent 4a9a5ae commit e293dd8
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 4 deletions.
4 changes: 0 additions & 4 deletions ci/code_checks.sh
Original file line number Diff line number Diff line change
Expand Up @@ -125,7 +125,6 @@ if [[ -z "$CHECK" || "$CHECK" == "docstrings" ]]; then
-i "pandas.DatetimeIndex.is_leap_year SA01" \
-i "pandas.DatetimeIndex.microsecond SA01" \
-i "pandas.DatetimeIndex.minute SA01" \
-i "pandas.DatetimeIndex.month SA01" \
-i "pandas.DatetimeIndex.nanosecond SA01" \
-i "pandas.DatetimeIndex.quarter SA01" \
-i "pandas.DatetimeIndex.round SA01" \
Expand All @@ -138,7 +137,6 @@ if [[ -z "$CHECK" || "$CHECK" == "docstrings" ]]; then
-i "pandas.DatetimeIndex.to_pydatetime RT03,SA01" \
-i "pandas.DatetimeIndex.tz SA01" \
-i "pandas.DatetimeIndex.tz_convert RT03" \
-i "pandas.DatetimeIndex.year SA01" \
-i "pandas.DatetimeTZDtype SA01" \
-i "pandas.DatetimeTZDtype.tz SA01" \
-i "pandas.DatetimeTZDtype.unit SA01" \
Expand Down Expand Up @@ -324,7 +322,6 @@ if [[ -z "$CHECK" || "$CHECK" == "docstrings" ]]; then
-i "pandas.Series.dt.microsecond SA01" \
-i "pandas.Series.dt.microseconds SA01" \
-i "pandas.Series.dt.minute SA01" \
-i "pandas.Series.dt.month SA01" \
-i "pandas.Series.dt.month_name PR01,PR02" \
-i "pandas.Series.dt.nanosecond SA01" \
-i "pandas.Series.dt.nanoseconds SA01" \
Expand All @@ -343,7 +340,6 @@ if [[ -z "$CHECK" || "$CHECK" == "docstrings" ]]; then
-i "pandas.Series.dt.tz_convert PR01,PR02,RT03" \
-i "pandas.Series.dt.tz_localize PR01,PR02" \
-i "pandas.Series.dt.unit GL08" \
-i "pandas.Series.dt.year SA01" \
-i "pandas.Series.dtype SA01" \
-i "pandas.Series.empty GL08" \
-i "pandas.Series.eq PR07,SA01" \
Expand Down
10 changes: 10 additions & 0 deletions pandas/core/arrays/datetimes.py
Original file line number Diff line number Diff line change
Expand Up @@ -1541,6 +1541,11 @@ def isocalendar(self) -> DataFrame:
"""
The year of the datetime.
See Also
--------
DatetimeIndex.month: The month as January=1, December=12.
DatetimeIndex.day: The day of the datetime.
Examples
--------
>>> datetime_series = pd.Series(
Expand All @@ -1564,6 +1569,11 @@ def isocalendar(self) -> DataFrame:
"""
The month as January=1, December=12.
See Also
--------
DatetimeIndex.year: The year of the datetime.
DatetimeIndex.day: The day of the datetime.
Examples
--------
>>> datetime_series = pd.Series(
Expand Down

0 comments on commit e293dd8

Please sign in to comment.