Courseiva
ModelinghardMultiple ChoiceObjective-mapped

MLS-C01 Modeling Practice Question

A data scientist is building a model to predict customer churn. The dataset contains categorical features with high cardinality (e.g., ZIP code, customer ID). Which encoding method is MOST suitable?

⚠ Common exam trap

A common mix-up: candidates choose one-hot encoding as the default for categorical data, failing to recognize that high cardinality makes it impractical, or they pick label encoding assuming it is safe for tree models, but it introduces false ordinality that can degrade performance.

Answer choices

Why each option matters

Answer the question above first, then reveal the full breakdown to understand why each option is right or wrong.

Correct answer & explanation

Target encoding

Target encoding is most suitable for high-cardinality categorical features because it replaces each category with the mean of the target variable for that category, effectively capturing the predictive signal while keeping the feature space dense. This avoids the curse of dimensionality from one-hot encoding and the arbitrary ordinality of label encoding, which can mislead tree-based models.

Answer analysis

Option-by-option breakdown

For each option: why learners choose it and why it is or isn't the right answer here.

  • One-hot encoding

    Why it's wrong here

    One-hot encoding creates too many features.

  • Label encoding

    Why it's wrong here

    Label encoding implies order which may not exist.

  • Hashing encoding

    Why it's wrong here

    Hashing may cause collisions and lose information.

  • Target encoding

    Why this is correct

    Target encoding captures information without expanding dimensionality.

About these practice questions

This MLS-C01 question is part of Courseiva's 1,672-question bank — original exam-style content with full explanations and wrong-answer analysis, never real exam questions or exam dumps. Learn why practice questions differ from exam dumps →

How Courseiva writes practice questions · Editorial policy

JA

Written by Johnson Ajibi, MSc IT Security

Senior Network & Security Engineer · founder of Courseiva

This MLS-C01 practice question is part of Courseiva's free Amazon Web Services certification practice question bank. Courseiva provides original exam-style practice questions with explanations, topic-based practice, mock exams, readiness tracking, and study analytics to help learners prepare for the MLS-C01 exam.