📅  最后修改于: 2022-03-11 14:46:58.644000             🧑  作者: Mango
# We can use label encoding on multiple column at once by using method
from sklearn.preprocessing import LabelEncoder
df[cat_c] = df[cat_c].apply(LabelEncoder().fit_transform)