2
$\begingroup$

I am trying to evaluate a multi-class classification model, say Random Forest, I built in R. So far, my approach has been looking at the ConfusionMatrix from the caret package and other results that are calculated by that function, but it gives me only a class wise result. I am also calculating micro and macro averages for estimating the overall accuracy for the model.

Now, when I am trying to plot the ROC curve, I have two options:

  • One-vs-One approach: gives me nC2 combinations of ROC curves, which I am not sure how to interpret. The pROC package implements this method, suggested by Hand and Till because it supposedly gives a more accurate AUC.
  • One-vs-All approach: gives me n ROC curves and their corresponding AUC. A reference for this I found in another similar question

Is there any preferred method for plotting the ROC in this scenario? If so, why?

And can this choice of it being either One-vs-One or One-vs-All be generalized to any multi-class model?

$\endgroup$

1 Answer 1

3
$\begingroup$

When you use roc curves, you are saying that

  • misclassification costs are not the same for different types of mistakes. If they were, you would just optimize classification accuracy which would be the most adequate objective function and also more intuitive than all of the alternatives.
  • you don't know the actual misclassification costs and therefore want to compare classification based on multiple cutoffs. If you did, you would just put the actual costs in the objective function to optimize.

If both these circumstances are given, you may look into roc curves. Though F-measure and kappa are worth considering as well.

The one vs. all approach reflects that some classes like $A$ may or may not be more costly to miss than other classes $B$ or $C$. Each roc curve sweeps over possible cutoffs for $A$ vs. ($B$ or $C$), $B$ vs. ($A$ or $C$) and the last one for $C$ vs. ($A$ or $B$)

The one vs. one approach is only necessary if for a given class $A$, it is also different to mistake an $A$ for a $B$ than to mistake an $A$ for a $C$. This is the most general case, but also the least intuitive.

$\endgroup$
1
  • $\begingroup$ +1. Little side note, though: In the single label (but multi-class) case, the two implicit assumptions you point out are correct. If you are in the multi-label multi-class situation, however, a rank-based evaluation metric like ROC is a very suitable metric, even when the costs of misclassification are not asymmetric $\endgroup$
    – KenHBS
    Commented Jan 22, 2018 at 11:49

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.