File Exchange

image thumbnail


version (48.8 KB) by Jaroslaw Tuszynski
Calculates Area under ROC curve (AUC) for a vector or for each column of a matrix.


Updated 27 Nov 2012

View Version History

View License

Function colAUC calculates Area under ROC curve (AUC) for a vector or for
each column of a matrix.

The main properties of this code:
* Ability to work with multi-dimensional data.
* Ability to work with multi-class datasets.
* Speed - this code was written to calculate AUC's for large number of
features, fast.
* Two different algorithms are provided one based on integrating ROC
curves and one based on Wilcoxon Rank Sum Test aka. Mann-Whitney U Test.
* Function can be used to plot ROC curves.

Cite As

Jaroslaw Tuszynski (2021). colAUC (, MATLAB Central File Exchange. Retrieved .

Comments and Ratings (5)


I'm sorry but it is not clear how to get multiclass auc if I have Y as the true label of 1...c classes and Yest as 1...c column vector with predictive score for each instance belong to certain class. The output auc is a c x c x(c-1)/2 combination in your case, take mean(auc) returns c auc values.

Jaroslaw Tuszynski

Reply to JR King: See new version

JR King

Thanks a lot, very useful.

I would remove the absolute computation: ( auc = 0.5 + abs(0.5-auc);) as it is indicative of the effect direction which is necessary for most statistical analyses.

JR King


MATLAB Release Compatibility
Created with R2010a
Compatible with any release
Platform Compatibility
Windows macOS Linux

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!