Feature Engineering: One-Hot Encoding

Learn how to encode categorical features using one-hot encoding.

In this lesson, we’ll start applying feature engineering techniques to our telecom customer dataset. We’ll create, format, and encode features for the supervised machine learning algorithm that will predict customer churn.


We have 15 categorical features to encode because the machine learning algorithm we’ll use expects all parameters to be numeric. We will use one-hot encoding for this. The encoding will be performed as follows.

Get hands-on with 1200+ tech skills courses.