Omni Calculator logo

Our sensitivity and specificity calculator is the quickest way to calculate all the necessary data needed for medical research statistics and test evaluation.

With our online sensitivity and specificity calculator, you're able to compute PPV, NPV, the positive and negative likelihood ratio, and the accuracy (see accuracy calculator).

We'll show you how to calculate the negative predictive value from sensitivity and specificity, explain the sensitivity of a test, and describe all you need to know about the NPV and PPV in statistics.

How to use the sensitivity and specificity calculator?

Calculating sensitivity, specificity, PPV, and NPV requires the same four pieces of information:

  1. Number of true positive cases (TP) ✅✅

    Number of people with the disease who tested positive.

  2. Number of true negative cases (TN) ❌❌

    Number of people without the disease who tested negative.

  3. Number of false positive cases (FP) ❌✅

    Number of people without the disease who tested positive.

  4. Number of false negative cases (FN) ✅❌

    Number of people with the disease who tested negative.

↓ Find these values with our 2x2 table method presented below. ↓

2x2 table for sensitivity and specificity

sensitivity and specificity table

Take a longer look at the table – it's an easy, visual way to understand the meaning of all presented variables.

How do I calculate sensitivity?

Sensitivity – the proportion of people with the disease who tested positive compared to the number of all the people with the disease, regardless of their test result.

To calculate sensitivity, we'll need:

  • Number of true positive cases (TP); and
  • Number of false negative cases (FN).

And the following sensitivity equation:

Sensitivity = TP / (TP + FN)

TP + FN = Total number of people with the disease; and

TN + FP = Total number of people without the disease.

How do I calculate specificity?

Specificity – the proportion of healthy people that tested negative compared to the total number of people without the disease, no matter their test result.

To calculate specificity, we'll need:

  • Number of true negative cases (TN); and
  • Number of false positive cases (FP).

And the following specificity equation:

Specificity = TN / (FP + TN)

You might also be interested in a couple of our other statistical calculations, such as the T-test calculator and the standard deviation calculator.

How do I calculate the accuracy of a test?

Accuracy is just the ratio of correct results to all the results of a test.

The accuracy formula is one of the easiest ones to remember:

Accuracy = (TP + TN) / (TP + TN + FP + FN)

How to calculate positive predictive value? – PPV, NPV

Here we present the theoretical basis of our NPV and PPV calculator – this is how we can calculate the Negative Predictive Value from sensitivity and specificity.

You'll need:

  • Sensitivity (also: true positive, false negative);
  • Specificity (also: true negative, false positive); and
  • Prevalence – the amount of the population affected by a particular disease at the time you are interested in, given in %.

Follow the Positive Predictive Value formula (PPV) presented below:

PPV = (Sensitivity × Prevalence)/[(Sensitivity × Prevalence) + ((1 - Specificity) × (1 - Prevalence))]

PPV depends on the prevalence – it measures the precision of a test, which is the probability that a positive test result is indeed correct.

Negative Predictive Value formula (NPV):

NPV =(Specificity × (1 - Prevalence))/[((1 - Sensitivity) × Prevalence) + (Specificity × (1 - Prevalence))]

NPV also depends on the prevalence of the disease – it describes the probability that a negative test result is indeed correct.

In the next section, we'll explain the principles behind our probability ratios calculator.

How do I calculate likelihood ratio?

To compute the positive and negative likelihood ratio given sensitivity and specificity, apply the following formulas:

  1. Positive likelihood ratio:

    Positive likelihood ratio = Sensitivity / (1 - Specificity)

  2. Negative likelihood ratio:

    Negative likelihood ratio = (1 - Sensitivity) / Specificity

Have you already calculated everything for your test's statistical evaluation? Step up the game and try our post-test probability calculator. 🎲

FAQ

How do I compute PPV given TP and FP?

PPV = TP / (TP + FP). That is, PPV is the proportion of true positive results to all positive results (both true and false positives).

How do I interpret the positive likelihood ratio?

Both positive and negative likelihood ratios describe the value of a test:

  • Positive likelihood ratio represents the possibility that the person with the disease will test positive; and

  • Negative likelihood ratio represents the possibility that the healthy person will test negative.

How do I interpret the positive predictive value PPV?

Here's how to understand the values of PPV and NPV:

  • PPV measures the precision of a test, which is the probability that a positive test result is indeed correct; while

  • NPV measures the probability that a negative test result is correct.

Łucja Zaborowska, MD, PhD candidate
table for sensitivity and specificity
True positive
True negative
False positive
False negative
Prevalence
%
Results
Sensitivity
%
Specificity
%
Positive likelihood ratio
Negative likelihood ratio
PPV
%
NPV
%
Accuracy
%
Check out 25 similar probability theory and odds calculators 🎲
AccuracyBayes theoremBirthday paradox… 22 more
People also viewed…

Books vs e-Books

The books vs. e-books calculator answers the question: how ecological is your e-book reader? 📚

Land Gasoline generation

fds

Sample size

The sample size calculator determines the sample size required for the result to be statistically significant.

Social Media Time Alternatives

Check what you could have accomplished if you get out of your social media bubble.
Copyright by Omni Calculator sp. z o.o.
Privacy, Cookies & Terms of Service