Preparing Practice Exam…
Please wait a moment while the system generates the exam questions, answers, and study session.
Please wait a moment while the system generates the exam questions, answers, and study session.
Databricks Certified Machine Learning Associate · Databricks
Select one answer.
Written by other learners. Comments can disagree with the marked answer — check the official documentation when in doubt.
- Correct answer : A — `Imputer` defaults to `strategy='mean'`, so the outlier-sensitive mean is used instead of the median; the code must set `strategy='median'` explicitly to match the intended behavior. A . `pyspark.ml.feature.Imputer` defaults to the mean strategy when `strategy` is not passed, so this code silently fills the skewed column with an outlier-sensitive mean rather than the intended median, and `strategy='median'` must be added explicitly. B . The default strategy for `pyspark.ml.feature.Imputer` is mean, not median, so this code does not already produce the intended behavior and would fill the skewed column with a value pulled toward its outliers. C . `inputCols` and `outputCols` are allowed to differ, which is how a new filled column is created alongside the original; this code's mismatched names are valid and do not cause a `fit`-time error. D . Mode is not the default strategy for `pyspark.ml.feature.Imputer`; the default is mean, so describing this failure as a mode-based fill misidentifies both the actual behavior and the fix needed.