%let mu1=3; %let mu2=4; %let cut=4; Data ROC; do L = 0 to 10 by .02; FX = exp(-0.5*(L-&mu1)**2)/sqrt(2*3.14159); FY = exp(-0.5*(L-&mu2)**2)/sqrt(2*3.14159); ROC_X = probnorm(L-&mu1); ** proportion of 1s to your left; ROC_Y = probnorm(L-&mu2); ** proportion of 0s to your left; ref=.; If round(L-&cut,.01)=0 then ref=ROC_X; output; end; proc print; goptions reset=all; proc gplot; plot (FX FY)*L/overlay href=&cut; Title "Probability of 1 versus (say) Logit"; Title2 c=blue h=1.5 "Blue curve: Logits of the 1s"; Title3 c=red h=1.5 " Red curve: Logits of the 0s"; symbol1 v=none i=join w=2; run; PROC GPLOt; plot (ROC_X ref)*ROC_Y/overlay; title "ROC curve"; symbol1 v=none i=join w=3 c=black; symbol2 v=dot i=none h=2 c=red; run;