Databricks Machine Learning Associate Question 525
Single answerYou are working on a dataset in Databricks that contains missing values in a numeric column representing monthly sales. To prepare the data for a machine learning model, you decide to impute the missing values. Which of the following imputation methods would be most appropriate if the sales data follows a normal distribution?
- A
Impute missing values with the mode of the column
- B
Impute missing values with the mean of the column
- C
Impute missing values with the median of the column
- D
Drop all rows with missing values in the column
Show answer and explanation
Correct answer: B
Explanation
For normally distributed numeric data, the mean is the best choice for imputing missing values because it represents the central tendency of the distribution. While the median and mode can also be used for imputation, they are more appropriate for skewed distributions or categorical data, respectively. Dropping rows with missing values is generally discouraged unless the proportion of missing data is very small.
- A. Incorrect.
The mode is best suited for categorical data or skewed numeric data, not for normally distributed numeric data, so this option is not appropriate.
- B. Correct.
The mean is the most appropriate imputation method for normally distributed numeric data, as it accurately represents the central tendency of such distributions.
- C. Incorrect.
The median is better suited for skewed numeric data, as it is less sensitive to outliers, but it is not optimal for normally distributed data.
- D. Incorrect.
Dropping rows with missing values should be avoided unless the missing data is minimal, as this can lead to loss of valuable information.