
Answer-first summary for fast verification
Answer: Use precision, recall, and F1-score, implemented through binary classification evaluators.
In scenarios with class imbalance, accuracy can be misleading. Precision, recall, and F1-score provide a more comprehensive evaluation by considering true positives, false positives, and false negatives. Implementing these metrics using binary classification evaluators in Spark ML ensures a thorough evaluation of the model's performance.
Author: LeetQuiz Editorial Team
Ultimate access to all questions.
Given a dataset with high dimensionality and class imbalance, describe how you would evaluate a machine learning model trained using Spark ML. Discuss the metrics you would use, why they are appropriate for this scenario, and how you would implement them in Spark ML. Additionally, explain any challenges you might face in evaluating such a model and how you would address them.
A
Use only accuracy as the metric.
B
Use precision, recall, and F1-score, implemented through binary classification evaluators.
C
Ignore class imbalance and use mean squared error.
D
Use only ROC-AUC as the metric.
No comments yet.