13Binary Prediction Problem Test Properties True Disease StatusPosNegTestCriterionTPFPFNTNPNP+ NAccuracy= Probability that the test yields a correct result.= (TP+TN) / (P+N)
14Binary Prediction Problem Test Properties True Disease StatusPosNegTestCriterionTPFPFNTNPNP+ NSensitivity= Probability that a true case will test positive= TP / PAlso referred to as True Positive Rate (TPR) or True Positive Fraction (TPF).
15Binary Prediction Problem Test Properties True Disease StatusPosNegTestCriterionTPFPFNTNPNP+ NSpecificity= Probability that a true negative will test negative= TN / NAlso referred to as True Negative Rate (TNR) or True Negative Fraction (TNF).
16Binary Prediction Problem Test Properties True Disease StatusPosNegTestCriterionTPFPFNTNPNP+ N1-Specificity= Prob that a true negative will test positive= FP / NAlso referred to as False Positive Rate (FPR) or False Positive Fraction (FPF).
17Binary Prediction Problem Test Properties True Disease StatusPosNegTestCriterionTPFPFNTNPNP+ NPositive Predictive Value (PPV)= Probability that a positive test will truly have disease= TP / (TP+FP)
18Binary Prediction Problem Test Properties True Disease StatusPosNegTestCriterionTPFPFNTNPNP+ NNegative Predictive Value (NPV)= Probability that a negative test will truly be disease free= TN / (TN+FN)
20Binary Prediction Problem Test Properties Of these properties, only Se and Sp (and hence FPR) are considered invariant test characteristics.Accuracy, PPV, and NPV will vary according to the underlying prevalence of disease.Se and Sp are thus “fundamental” test properties and hence are the most useful measures for comparing different test criteria, even though PPV and NPV are probably the most clinically relevant properties.
21ROC CurvesNow assume that our test statistic is no longer binary, but takes on a series of values (for instance how many of five distinct risk factors a person exhibits).Clinically we make a rule that says the test is positive if the number of risk factors meets or exceeds some threshold (#RF > x)Suppose our previous table resulted from using x = 4.Let’s see what happens as we vary x.
22ROC Curves Impact of using a threshold of 3 or more RFs True Disease StatusPosNegTestCriterion45200245557007551009001000200800.27.75Se =27/100 = .45Acc =(27+727)/1000 = .75.81.14Sp =727/900 = .78PPV =27/200 = .18.91FPF = 1- Sp =.22NPV =727/800 = .93Se , Sp , and interestingly both PPV and NPV
23ROC Curves Summary of all possible options ThresholdTPRFPR60.0050.100.1140.270.1930.450.2220.7310.980.801.00As we relax our threshold for defining “disease,” our true positive rate (sensitivity) increases, but so does the false positive rate (FPR).The ROC curve is a way to visually display this information.
24ROC Curves Summary of all possible options x=5x=4x=2The diagonal line shows what we would expect from simple guessing (i.e., pure chance).ThresholdTPRFPR60.0050.100.1140.270.1930.450.2220.7310.980.801.00What might an even better ROC curve look like?
25ROC Curves Summary of a more optimal curve ThresholdTPRFPR60.0050.100.0140.770.0230.900.0320.950.0410.990.401.00Note the immediate sharp rise in sensitivity. Perfect accuracy is represented by upper left corner.
26ROC Curves Use and interpretation The ROC curve allows us to see, in a simple visual display, how sensitivity and specificity vary as our threshold varies.The shape of the curve also gives us some visual clues about the overall strength of association between the underlying test statistic (in this case #RFs that are present) and disease status.
27ROC Curves Use and interpretation The ROC methodology easily generalizes to test statistics that are continuous (such as lung function or a blood gas). We simply fit a smoothed ROC curve through all observed data points.
29ROC Curves Area under the curve (AUC) The total area of the grid represented by an ROC curve is 1, since both TPR and FPR range from 0 to 1.The portion of this total area that falls below the ROC curve is known as the area under the curve, or AUC.
30Area Under the Curve (AUC) Interpretation The AUC serves as a quantitative summary of the strength of association between the underlying test statistic and disease status.An AUC of 1.0 would mean that the test statistic could be used to perfectly discriminate between cases and controls.An AUC of 0.5 (reflected by the diagonal 45° line) is equivalent to simply guessing.
31Area Under the Curve (AUC) Interpretation The AUC can be shown to equal the Mann-Whitney U statistic, or equivalently the Wilcoxon rank statistic, for testing whether the test measure differs for individuals with and without disease.It also equals the probability that the value of our test measure would be higher for a randomly chosen case than for a randomly chosen control.
32Area Under the Curve (AUC) Interpretation FPRTPR1ROC CurveAUC ~0.540controlscases
33Area Under the Curve (AUC) Interpretation ~.95TPR1FPRROC Curvecontrolscases
34Area Under the Curve (AUC) Interpretation What defines a “good” AUC?Opinions varyProbably context specificWhat may be a good AUC for predicting COPD may be very different than what is a good AUC for predicting prostate cancer
35Area Under the Curve (AUC) Interpretation = excellent= good= fair= poor= failRemember that <.50 is worse than guessing!
36Area Under the Curve (AUC) Interpretation = excellent= very good= good= fair
37ROC Curves Comparing multiple ROC curves Suppose we have two candidate test statistics to use to create a binary decision rule. Can we use ROC curves to choose an optimal one?
38ROC Curves Comparing multiple ROC curves Adapted from curves at:
40ROC Curves Comparing multiple ROC curves We can formally compare AUCs for two competing test statistics, but does this answer our question?AUC speaks to which measure, as a continuous variable, best discriminates between cases and controls?It does not tell us which specific cutpoint to use, or even which test statistic will ultimately provide the “best” cutpoint.
41ROC Curves Choosing an optimal cutpoint The choice of a particular Se and Sp should reflect the relative costs of FP and FN results.What if a positive test triggers an invasive procedure?What if the disease is life threatening and I have an inexpensive and effective treatment?How do you balance these and other competing factors?See excellent discussion of these issues at
42ROC Curves Generalizations These techniques can be applied to any binary outcome. It doesn’t have to be disease status.In fact, the use of ROC curves was first introduced during WWII in response to the challenge of how to accurately identify enemy planes on radar screens.
43ROC Curves Final cautionary notes We assume throughout the existence of a gold standard for measuring “disease,” when in practice no such gold standard exists.COPD, asthma, even cancer (can we truly rule out the absence of cancer in a given patient?)As a result, even Se and Sp may not be inherently stable test characteristics, but may vary depending on how we define disease and the clinical context in which it is measured.Are we evaluating the test in the general population or only among patients referred to a specialty clinic?Incorrect specification of P and N will vary in these two settings.