Matthews correlation coefficient calculator
Summarize binary prediction agreement from all four confusion-matrix counts.
inputs.
Calculator
How to use this calculator
Calculate Matthews correlation coefficient from true and false positives and negatives.
- Enter True positives, False positives, False negatives, True negatives. Match the units shown beside each field and review the result together with the assumptions below.
- Read the worked example below to check the expected input format and result.
- Compare another scenario by changing one input at a time. Use Reset to return to the starting values.
Summarize binary classification agreement
Calculate the Matthews correlation coefficient (MCC) from the four cells of a binary confusion matrix.
Inputs and units
- True positives: Actual positives predicted positive.
- False positives: Actual negatives predicted positive.
- False negatives: Actual positives predicted negative.
- True negatives: Actual negatives predicted negative.
Formula and method
MCC = (TP × TN − FP × FN) ÷ √((TP+FP)(TP+FN)(TN+FP)(TN+FN)). The denominator is undefined if any factor is zero.
Worked example
For TP=42, FP=8, FN=10, and TN=140, MCC ≈ 0.7634, indicating positive agreement between predictions and the reference labels.
Interpreting the result
MCC ranges from −1 to +1: +1 is perfect agreement, 0 is no linear association, and −1 is total disagreement under the binary encoding.
Assumptions and limits
MCC summarizes one threshold and one labeled dataset. It does not show calibration, class-specific costs, uncertainty, data leakage, or performance on a different population.
Method references
Frequently asked questions
Does MCC use all four confusion-matrix cells?
Yes. It combines true and false positives and negatives in one correlation-style statistic.
Does a high MCC prove a model is useful?
No. Check the validation design, threshold, subgroup performance, calibration, and consequences of errors.
How do I use the Matthews correlation coefficient calculator?
Enter True positives, False positives, False negatives, True negatives. Match the units shown beside each field and review the result together with the assumptions below.
What is a worked example of Matthews correlation coefficient?
For TP=42, FP=8, FN=10, and TN=140, MCC ≈ 0.7634, indicating positive agreement between predictions and the reference labels.
What does the Matthews correlation coefficient calculator calculate?
Calculate Matthews correlation coefficient from true and false positives and negatives.
Good calculators show their work.
CalcWorldHub is built around clear inputs and visible assumptions. Results are estimates for planning; check official sources or your provider’s terms when exact figures matter.