diff --git a/pandas/core/series.py b/pandas/core/series.py index 1449b78ee91d8..b4e8696ad9e13 100644 --- a/pandas/core/series.py +++ b/pandas/core/series.py @@ -4622,6 +4622,15 @@ def isin(self, values) -> "Series": 4 True 5 False Name: animal, dtype: bool + + Strings and integers are distinct and are therefore not comparable: + + >>> pd.Series([1]).isin(['1']) + 0 False + dtype: bool + >>> pd.Series([1.1]).isin(['1.1']) + 0 False + dtype: bool """ result = algorithms.isin(self._values, values) return self._constructor(result, index=self.index).__finalize__(