Because I would like to calculate the sample size for comparing the area under the curve (AUC) of 2 models (cross-sectional study, predictor = continuous variable). Can you point me which function in R solves it.

  • $\begingroup$ +1 for a good question, as I'm also interested in this. Perhaps simulation? Irrespective of the solution, I'd like to see exactly how this was done. Or, perhaps a formula. $\endgroup$
    – pmgjones
    Commented Oct 3, 2011 at 17:32

2 Answers 2


I could not find an R-package that would solve the problem. But I can remember reading the book "Statistical Methods in Diagnostic Medicine" by Zhou, Obuchowski and McClish (Amazon Link). They give a method (too long to reproduce it here for now) for determining the sample size and refer to 2 publications:

Obuchowski NA. Nonparametric analysis of clustered ROC curve data. Biometrics. 1997 Jun;53(2):567-78. PubMed PMID: 9192452.

which IMHO should be instead:

Obuchowski NA, McClish DK. Sample size determination for diagnostic accuracy studies involving binormal ROC curve indices. Stat Med. 1997 Jul 15;16(13):1529-42. PubMed PMID: 9249923.

The second one is a technical report at the University of Chicago by Metz, Kronman and Wang (1989): FORTRAN Program ROCPWR. I could not find this one but googling led me to http://www-radiology.uchicago.edu/krl/KRL_ROC/ROC_analysis_by_topic4.htm I could not find a working link to download the software, though. Maybe someone other does or you contact the authors.

I hope this helps at least a little bit...


  • $\begingroup$ Thank you so much! I will study these article carefully. $\endgroup$
    – Duc Tan Ha
    Commented Oct 15, 2011 at 1:12
  • $\begingroup$ In the meantime I found a way to download the FORTRAN software: you have to register on the page metz-roc.uchicago.edu and there you find an 32-bit exe-file as well as FORTRAN source code. $\endgroup$
    – psj
    Commented Oct 19, 2011 at 13:33

There is a just released R Package called pROC which does what you want using the function power.roc.test.

Documentation of the package: https://cran.r-project.org/web/packages/pROC/pROC.pdf

I Hope it helps


Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.