Why is Target Encoding prone to data leakage during the model training process?

Data Science Hard

Data Science — Hard

Why is Target Encoding prone to data leakage during the model training process?

Key points

  • Target encoding incorporates target information into features
  • Leakage occurs if statistics are calculated on the full dataset
  • Cross-validation or smoothing is required to prevent overfitting

Ready to go further?

Related questions