I'm trying to use OneHotEncoding on the categorical variables of the following dataset.
Error
ohe = OneHotEncoder(categorical_features = [5])
X = ohe.fit_transform(data).toarray()
Can someone help me to understand why this error occurs and how to solve this?
I'm trying to use the OneHotEncoder
and here's what I've done so far: