A nominal category has no meaningful order. Which encoding is generally safer than assigning arbitrary increasing integers to a linear model?

Published
  1. The average target from the full dataset including test labels
  2. Integers chosen by alphabetical order without evaluating their effect
  3. One-hot encoding with a planned unseen-category policy
  4. A random new code for each inference call

Comments — 0