When an algorithm involves more than two classes, which technique is BEST suited to help a data scientist verify its accuracy?
A confusion matrix extends naturally to multi-class problems, producing an N x N table that cross-tabulates predicted labels against actual labels for each of the N classes. From this matrix, a data scientist can derive overall accuracy as well as per-class metrics such as precision, recall, and F1-score, making it possible to assess how well the algorithm performs across all classes rather than just an aggregate score. Linear regression is designed for predicting continuous outputs, not for evaluating classification accuracy, and K-NN is a classification algorithm itself rather than an evaluation technique, so neither is appropriate for assessing multi-class classification accuracy.
Community Discussion