Databricks ML Associate Practice Question 5: Impute Skewed Feature
Databricks Certified Machine Learning Associate · Test 1 · question 5 of 10
A continuous feature, annual_income, is missing for 8% of rows. Its distribution is heavily right-skewed: most values fall between 30,000 and 90,000, but a few accounts report more than 5,000,000. You want to fill the missing values with a single statistic.
Which statistic is most appropriate?
Show answer and explanation
Answer:
Pick the imputation statistic after looking at the distribution. With a heavy right skew, a few multi-million values pull the mean far above the typical value, but the median stays in the middle of the bulk of the data. Median imputation therefore gives missing rows a realistic, typical value. Mean, median, and most-frequent are the standard strategies; the Databricks AutoML imputers option offers mean, median, most_frequent, and constant.
Option A would work for a roughly symmetric feature. Here the mean is inflated by the outliers, so every imputed row gets an income higher than most real customers have.
Option C gets the default backwards. The mode (most frequent value) suits categorical features. A continuous feature has few exactly repeated values, so its mode is often arbitrary.
Option D technically stays inside the observed range, but it assigns every missing row the most extreme outlier. That is the worst available choice.
Reference: AutoML Python API reference