A00-240 · Question #39
What is a benefit to performing data cleansing (imputation, transformations, etc.) on data after partitioning the data for honest assessment as opposed to performing the data cleansing prior to partit
The correct answer is D. It allows for the determination of the effectiveness of the cleansing method.. Performing data cleansing after partitioning prevents data leakage - when you compute imputation statistics (like the mean) or fit transformations on the full dataset before splitting, test-set information bleeds into your training process, making your test set no longer truly "u
Question
Options
- AIt makes inference on the model possible.
- BIt is computationally easier and requires less time.
- CIt omits the training (and test) data sets from the benefits of the cleansing methods.
- DIt allows for the determination of the effectiveness of the cleansing method.
How the community answered
(39 responses)- A10% (4)
- B8% (3)
- C21% (8)
- D62% (24)
Explanation
Performing data cleansing after partitioning prevents data leakage - when you compute imputation statistics (like the mean) or fit transformations on the full dataset before splitting, test-set information bleeds into your training process, making your test set no longer truly "unseen." By cleansing after partitioning, you fit the cleansing parameters only on training data and apply them independently to the test set, so your evaluation honestly reflects how the cleansing method performs on new data - that's option D.
Why the distractors fail:
- A is wrong because inference is possible regardless of when cleansing occurs; the order of partitioning vs. cleansing doesn't gate model inference.
- B is wrong and backwards - cleansing once on the full dataset before splitting is computationally simpler; doing it separately per partition is more work.
- C describes a disadvantage, not a benefit, and is factually misleading - cleansing after partitioning still applies to both sets, just independently.
Memory tip: Think "fit on train, apply to test." If you cleanse before splitting, the test set secretly informed your cleansing parameters - poisoning the honest assessment you were trying to preserve by holding that data out in the first place.
Topics
Community Discussion
No community discussion yet for this question.