Sensitivity, Specificity, and Incidence

Testing, whether done in the medical field or elsewhere, generally has what is known as sensitivity and specificity. Sensitivity is the fraction of tested subjects who truly have some
characteristic that the test will say they have. Specificity is the fraction of tested subjects who truly do not have some characteristic that the test will say they do not have. This Demonstration shows how the number of true positives, false positives, false negatives, and true negatives can be calculated by using data regarding sensitivity, specificity, and the incidence in the tested population of a particular characteristic.



  • [Snapshot]
  • [Snapshot]
  • [Snapshot]


If the grid is represented as , then sensitivity is and specificity is Incidence is .
The sliders do not have a linear response since it is often important to control fine levels of detail at the upper levels of sensitivity and specificity and at the lower levels of incidence.
Snapshot 1: With low incidence conditions, a positive result on even a very sensitive test does not suggest by any means that a subject is truly positive.
Snapshot 2: With high incidence conditions, a positive result on a very sensitive test strongly suggests that a subject is truly positive.
Snapshot 3: With very high incidence conditions, even not highly specific or sensitive tests are rather good predictors.
    • Share:

Embed Interactive Demonstration New!

Just copy and paste this snippet of JavaScript code into your website or blog to put the live Demonstration on your site. More details »

Files require Wolfram CDF Player or Mathematica.

Mathematica »
The #1 tool for creating Demonstrations
and anything technical.
Wolfram|Alpha »
Explore anything with the first
computational knowledge engine.
MathWorld »
The web's most extensive
mathematics resource.
Course Assistant Apps »
An app for every course—
right in the palm of your hand.
Wolfram Blog »
Read our views on math,
science, and technology.
Computable Document Format »
The format that makes Demonstrations
(and any information) easy to share and
interact with.
STEM Initiative »
Programs & resources for
educators, schools & students.
Computerbasedmath.org »
Join the initiative for modernizing
math education.
Step-by-Step Solutions »
Walk through homework problems one step at a time, with hints to help along the way.
Wolfram Problem Generator »
Unlimited random practice problems and answers with built-in step-by-step solutions. Practice online or make a printable study sheet.
Wolfram Language »
Knowledge-based programming for everyone.
Powered by Wolfram Mathematica © 2018 Wolfram Demonstrations Project & Contributors  |  Terms of Use  |  Privacy Policy  |  RSS Give us your feedback
Note: To run this Demonstration you need Mathematica 7+ or the free Mathematica Player 7EX
Download or upgrade to Mathematica Player 7EX
I already have Mathematica Player or Mathematica 7+