Receiver operating characteristic
Often abbreviated to ROC curve. In the context of medicine, it is a statistical tool used to evaluate the performace of a diagnostic test, particularly to decide what value to use as the cut-off between normal and 'disease'. A good test will have a large separation between the normal and disease population.
More commonly, there is overlap of the two distributions. If a high test results is supposed to indicate disease, then some normal patients may have a high test value (i.e. a false positive), while some of diseased patients will have low test values (i.e. a false negative). In this situation, lowering the threshold reduces sensitivity, but improves specificity.
The curve is created by calculating the true positive rate and false positive rate for a test using each test result as the threshold. (1 − specificity) is plotted against sensitivity, giving a graphical representation of the trade-off between the sensitivity and specificity of the test as the threshold value is altered.
The ideal 'curve', is formed from a vertical and horizontal line. Conversely, the worst case scenario is a 45° line (see green line in illustration - the test is no better than flipping a coin). In practice, most results produce a jagged plot somewhere in between, consisting of horizontal, vertical and diagonal lines that resemble a curve (although some statistical software packages can create a more smoothed curve by joining the points with best-fit curves)
The area under the curve gives a quantitative indication of how good the test is. The ideal curve has an area of 1, the worst case scenario is 0.5, with most practical test giving values of somewhere in between.
Generating the Curve
Graph -> ROC curve
- Two columns are required:
- The actual test values
- Real status of sample (e.g. disease=1, no disease=0)
- Use ROCR package.
The calculation can also be performed using Microsoft Excel™ using this spreadsheet file (licenced under ganfyd creative commons licence).