StatLabStudent EditionUser guideGalleryFeaturesAbout

ROC curve

Shows how well a score separates positive from negative cases across all cut-offs; the area under the curve (AUC) summarises it.

Menu: Analyze → Classify → ROC Curve…

When should I use it?

What are the assumptions?

How do I run it in StatLab?

  1. Choose the test variable(s), the state variable and the value that means positive.
  2. Untick 'Larger test result…' if lower scores indicate a positive state.
  3. With two or more test variables, tick 'Pairwise comparison' to test whether their AUCs differ (DeLong).

How do I read the output?

OutputMeaning
Area0.5 = no better than chance, 1 = perfect.
Std. Error, 95% CI, Asymptotic Sig.Uncertainty and the test of AUC = 0.5.
CoordinatesSensitivity and 1 − specificity at each cut-off; Youden's J = sensitivity + specificity − 1.
AUC Difference, z, Sig.Test of two correlated AUCs measured on the same cases.

Worked example

On the practice survey dataset (File → Sample dataset), this command — which the dialog's Paste button also produces — runs the procedure:

PROC rocCurve /vars=(score) /state=smoker /larger=YES /se=hm /coords=YES /compare=NO /positive=1.

Output tables: Case Processing Summary · Area Under the Curve · Coordinates of the Curve — Wellbeing score.

How would I report it in APA style?

The area under the ROC curve for Wellbeing score was .518, 95% CI [.415, .621], p = .726; the best cut-off by Youden's index was 64.541 (sensitivity .87, specificity .25).

Computed by StatLab's validated procedure code when this page was built. The example only illustrates the steps; choose variables that fit your own research question.

What are common mistakes?

Open StatLab   All guide topics