Diagnostic Accuracy · SENS-SPEC-CI

Sample Size for Estimation of Sensitivity and Specificity

Plan sample size for estimating diagnostic-test sensitivity and specificity using prevalence-adjusted Hajian-Tilaki formulas.

1. Information obtained from previous studies or literature

Expected proportion of participants who are reference-standard positive in the intended study population.

2. Information to be decided by the researcher

This is the desired half-width of the confidence interval, for example 5% means approximately +/-5 percentage points.

3. Results

Enter the diagnostic accuracy planning assumptions and select Calculate.

Formula, assumptions, limitations, and methodological note

Example clinical scenario

A researcher wants confidence intervals of specified precision for both sensitivity and specificity of a rapid malaria test against an appropriate reference standard.

Formula and methodological note

Scope and limitations: Use this calculator only for the diagnostic design named on this page and its stated independent or paired sampling assumptions. It does not cover clustering, repeated lesions, multiple-reader designs, prediction-model development, or non-inferiority/equivalence unless explicitly stated. The implemented normal or binormal approximation may be unsuitable near parameter boundaries or with sparse reference-standard groups. Where prevalence is used, it supports recruitment planning and does not necessarily form part of the core precision or hypothesis-test calculation.

This calculator implements the prevalence-adjusted method for estimating sensitivity and specificity of a diagnostic test.

N sensitivity = Z2 x Se x (1 - Se) / (d2 x Prev)

N specificity = Z2 x Sp x (1 - Sp) / (d2 x (1 - Prev))

N analysable = ceiling(max(N sensitivity, N specificity))

N recruitment = ceiling(N analysable / (1 - dropout))

Method references

  1. Buderer NMF. Statistical methodology: I. Incorporating the prevalence of disease into the sample size calculation for sensitivity and specificity. Academic Emergency Medicine. 1996;3(9):895-900. doi:10.1111/j.1553-2712.1996.tb03538.x.
  2. Hajian-Tilaki K. Sample size estimation in diagnostic test studies of biomedical informatics. Journal of Biomedical Informatics. 2014;48:193-204.

Suggested citation

Yaacob, Najib Majdi. “Sample Size for Estimation of Sensitivity and Specificity (SENS-SPEC-CI).” Web calculator. NajibMY, 2026. Accessed July 29, 2026. https://najibmy.netlify.app/tools/sample-size/diagnostic-accuracy/sensitivity-specificity/.