From f8a00789d09bca26997ebe480c1736cf11abaea6 Mon Sep 17 00:00:00 2001 From: Philip Khor <35039795+philip-khor@users.noreply.github.com> Date: Thu, 13 Aug 2020 11:42:46 +0800 Subject: [PATCH] is_categorical deprecated https://github.com/pandas-dev/pandas/pull/33385 --- category_encoders/utils.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/category_encoders/utils.py b/category_encoders/utils.py index 6f8e62e7..7e617f1f 100644 --- a/category_encoders/utils.py +++ b/category_encoders/utils.py @@ -18,7 +18,7 @@ def convert_cols_to_list(cols): return list(cols) elif isinstance(cols, tuple): return list(cols) - elif pd.api.types.is_categorical(cols): + elif pd.api.types.is_categorical_dtype(cols): return cols.astype(object).tolist() return cols