Matthews correlation coefficient
Description
The Matthews correlation coefficient is used in machine learning as a measure of the quality of binary (two-class) classifications. It takes into account true and false positives and negatives and is generally regarded as a balanced measure which can be used even if the classes are of very different sizes. The MCC is in essence a correlation coefficient between the observed and predicted binary classifications; it returns a value between −1 and +1. A coefficient of +1 represents a perfect prediction, 0 no better than random prediction and −1 indicates total disagreement between prediction and observation. While there is no perfect way of describing the confusion matrix of true and false positives and negatives by a single number, the Matthews correlation coefficient is generally regarded as being one of the best such measures. The MCC can be calculated directly from the confusion matrix.
Related formulasVariables
MCC | Matthews correlation coefficient (dimensionless) |
TP | Number of True Positives (correctly identified) (dimensionless) |
TN | Number of True Negatives (correctly rejected) (dimensionless) |
FP | Number of False Positive (incorrectly identified) (dimensionless) |
FN | Number of False Negatives ( incorrectly rejected) (dimensionless) |