
Answer-first summary for fast verification
Answer: Mean squared error (MSE), as it provides a measure of the average squared difference between the predicted and actual values.
In a Spark MLlib project, mean squared error (MSE) would be the most appropriate evaluation metric for comparing the performance of linear regression and decision tree models on a large dataset. MSE provides a measure of the average squared difference between the predicted and actual values, making it suitable for regression tasks where the target variable is continuous. Accuracy, ROC curve, and R-squared are more commonly used for classification tasks, where the target variable is categorical. Since both linear regression and decision trees can be used for regression tasks, MSE would be the most appropriate metric for comparing their performance.
Author: LeetQuiz Editorial Team
Ultimate access to all questions.
In a Spark MLlib project, you are tasked with comparing the performance of linear regression and decision tree models on a large dataset. Which of the following evaluation metrics would be most appropriate for comparing the performance of these models, and why?
A
Accuracy, as it measures the proportion of correct predictions made by the model.
B
Mean squared error (MSE), as it provides a measure of the average squared difference between the predicted and actual values.
C
Area under the receiver operating characteristic (ROC) curve, as it measures the model's ability to distinguish between different classes.
D
R-squared, as it measures the proportion of the variance in the target variable that is explained by the model.
No comments yet.