What does one-hot encoding do to a categorical variable?
- A Creates a binary indicator column for each category
- B Assigns each category an integer rank
- C Removes the column
- D Scales the categories to a range
Answer
Creates a binary indicator column for each category
It is unsuitable for very high cardinality, where it creates thousands of sparse columns. Target encoding is the usual alternative.





