Skip to content

Commit

Permalink
DOC: Fix Index.inferred type SA01 and Index.slice_locs RT03 errors (#…
Browse files Browse the repository at this point in the history
…58435)

Fix Index.inferred type SA01 and Index.slice_locs RT03 errors
  • Loading branch information
shriyakalakata authored Apr 26, 2024
1 parent 87b5a82 commit 362278a
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 2 deletions.
2 changes: 0 additions & 2 deletions ci/code_checks.sh
Original file line number Diff line number Diff line change
Expand Up @@ -118,7 +118,6 @@ if [[ -z "$CHECK" || "$CHECK" == "docstrings" ]]; then
-i "pandas.Index.get_loc PR07,RT03,SA01" \
-i "pandas.Index.get_slice_bound PR07" \
-i "pandas.Index.identical PR01,SA01" \
-i "pandas.Index.inferred_type SA01" \
-i "pandas.Index.insert PR07,RT03,SA01" \
-i "pandas.Index.intersection PR07,RT03,SA01" \
-i "pandas.Index.join PR07,RT03,SA01" \
Expand All @@ -128,7 +127,6 @@ if [[ -z "$CHECK" || "$CHECK" == "docstrings" ]]; then
-i "pandas.Index.ravel PR01,RT03" \
-i "pandas.Index.reindex PR07" \
-i "pandas.Index.slice_indexer PR07,RT03,SA01" \
-i "pandas.Index.slice_locs RT03" \
-i "pandas.Index.str PR01,SA01" \
-i "pandas.Index.symmetric_difference PR07,RT03,SA01" \
-i "pandas.Index.take PR01,PR07" \
Expand Down
6 changes: 6 additions & 0 deletions pandas/core/indexes/base.py
Original file line number Diff line number Diff line change
Expand Up @@ -2360,6 +2360,10 @@ def inferred_type(self) -> str_t:
"""
Return a string of the type inferred from the values.
See Also
--------
Index.dtype : Return the dtype object of the underlying data.
Examples
--------
>>> idx = pd.Index([1, 2, 3])
Expand Down Expand Up @@ -6471,6 +6475,8 @@ def slice_locs(self, start=None, end=None, step=None) -> tuple[int, int]:
Returns
-------
tuple[int, int]
Returns a tuple of two integers representing the slice locations for the
input labels within the index.
See Also
--------
Expand Down

0 comments on commit 362278a

Please sign in to comment.