Skip to content

Commit 77ca6ac

Browse files
[pre-commit.ci] auto fixes from pre-commit.com hooks
for more information, see https://pre-commit.ci
1 parent 9e38e8c commit 77ca6ac

File tree

1 file changed

+8
-8
lines changed

1 file changed

+8
-8
lines changed

pandas/core/indexes/base.py

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1265,7 +1265,7 @@ def take(
12651265
12661266
Examples
12671267
--------
1268-
>>> idx = pd.Index(['a', 'b', 'c'])
1268+
>>> idx = pd.Index(["a", "b", "c"])
12691269
>>> idx.take([2, 2, 1, 2])
12701270
Index(['c', 'c', 'b', 'c'], dtype='str')
12711271
"""
@@ -1345,7 +1345,7 @@ def repeat(self, repeats, axis: None = None) -> Self:
13451345
13461346
Examples
13471347
--------
1348-
>>> idx = pd.Index(['a', 'b', 'c'])
1348+
>>> idx = pd.Index(["a", "b", "c"])
13491349
>>> idx
13501350
Index(['a', 'b', 'c'], dtype='object')
13511351
>>> idx.repeat(2)
@@ -6067,14 +6067,14 @@ def get_indexer_non_unique(
60676067
60686068
Examples
60696069
--------
6070-
>>> index = pd.Index(['c', 'b', 'a', 'b', 'b'])
6071-
>>> index.get_indexer_non_unique(['b', 'b'])
6070+
>>> index = pd.Index(["c", "b", "a", "b", "b"])
6071+
>>> index.get_indexer_non_unique(["b", "b"])
60726072
(array([1, 3, 4, 1, 3, 4]), array([], dtype=int64))
60736073
60746074
In the example below there are no matched values.
60756075
6076-
>>> index = pd.Index(['c', 'b', 'a', 'b', 'b'])
6077-
>>> index.get_indexer_non_unique(['q', 'r', 't'])
6076+
>>> index = pd.Index(["c", "b", "a", "b", "b"])
6077+
>>> index.get_indexer_non_unique(["q", "r", "t"])
60786078
(array([-1, -1, -1]), array([0, 1, 2]))
60796079
60806080
For this reason, the returned ``indexer`` contains only integers equal to -1.
@@ -6086,8 +6086,8 @@ def get_indexer_non_unique(
60866086
below the first item is an array of locations in ``index``. The second
60876087
item is a mask shows that the first and third elements are missing.
60886088
6089-
>>> index = pd.Index(['c', 'b', 'a', 'b', 'b'])
6090-
>>> index.get_indexer_non_unique(['f', 'b', 's'])
6089+
>>> index = pd.Index(["c", "b", "a", "b", "b"])
6090+
>>> index.get_indexer_non_unique(["f", "b", "s"])
60916091
(array([-1, 1, 3, 4, -1]), array([0, 2]))
60926092
"""
60936093
target = self._maybe_cast_listlike_indexer(target)

0 commit comments

Comments
 (0)