Skip to main content
Calcimator

Confusion Matrix Analyzer

Analyze classification model performance from confusion matrix values. Calculate precision, recall, F1 score, MCC, accuracy, specificity, and more.

Inputs

Results

Accuracy

0.9

Precision

0.83

Recall (Sensitivity)

0.91

F1 Score

0.87

Matthews Correlation Coeff.0.79
Specificity0.89
False Positive Rate0.11
Balanced Accuracy0.9
Prevalence0.38
Total Samples145
How to Use This Calculator
  1. Enter the true positive, false positive, true negative, and false negative counts from your model.
  2. Review accuracy, precision, recall (sensitivity), and F1-score.
  3. Check specificity and AUC estimate for balanced evaluation.
  4. Identify whether false positives or false negatives are more costly for your use case.
  5. Adjust the classification threshold to trade off precision vs. recall based on business requirements.

What each input means

True Positives (TP)
Correctly predicted positive cases — the model said positive and it was positive.
False Positives (FP)
Incorrectly predicted positive cases — the model said positive but it was negative (Type I error).
True Negatives (TN)
Correctly predicted negative cases — the model said negative and it was negative.
False Negatives (FN)
Incorrectly predicted negative cases — the model said negative but it was positive (Type II error).

How this is calculated

Worked example, using the default values

  1. Identify Input Parameters
    4 parameters
    True Positives (TP) = 50, False Positives (FP) = 10, True Negatives (TN) = 80, False Negatives (FN) = 5 = 4 input(s) provided
  2. Calculate Accuracy
    Accuracy
    0.8966 = 0.8966
  3. Calculate Precision
    Precision
    0.8333 = 0.8333
  4. Calculate Recall
    Recall
    0.9091 = 0.9091
  5. Calculate Matthews Correlation Coeff.
    Matthews Correlation Coeff.
    0.7862 = 0.7862
  6. Calculate Specificity
    Specificity
    0.8889 = 0.8889

Engine last updated . Checked against 1 independently-derived test how we verify calculators.

The questions that sit next to this one — chosen by subject, including calculators filed under a different category.

More in Math & Statistics.