My confusion matrix looks as follows:

> table(actual, predicted_all)
actual    0    1
     0 1728 5261
     1 2088  168

While the AUC seems a bit too high in my eyes:

auc(actual, predicted_all) Area under the curve: 0.8391

I suspect I'm doing something wrong here, or is this not the case?


You have 6989 samples in class 0, 2256 samples in class 1, so it is easy to beat a random predictor, i.e. the AUROC should be significantly higher than 0.5.

This confusion matrix was simply computed using a threshold that makes your predictor tends to choose 1 more often.


Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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