From 47c4df98752cffd4f8809ff4a33cdc54a918b3b3 Mon Sep 17 00:00:00 2001 From: Teofanus Gary Setiawan Date: Sat, 29 Feb 2020 05:34:35 +0000 Subject: [PATCH] Improve pandas.Index.is_ docstring --- pandas/core/indexes/base.py | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/pandas/core/indexes/base.py b/pandas/core/indexes/base.py index ae2387f0fd7b4..47c759ac9614b 100644 --- a/pandas/core/indexes/base.py +++ b/pandas/core/indexes/base.py @@ -545,11 +545,17 @@ def is_(self, other) -> bool: Parameters ---------- other : object - other object to compare against. + Other object to compare against. Returns ------- - True if both have same underlying data, False otherwise : bool + bool + Boolean indicating if both object have same underlying data, + False otherwise. + + See Also + -------- + Index.identical : Works like Index.is_ but also check metadata. """ # use something other than None to be clearer return self._id is getattr(other, "_id", Ellipsis) and self._id is not None