Skip to main content

    Method document

    Sample size to estimate diagnostic likelihood ratios

    How many people must be tested to estimate the positive and negative likelihood ratios of a diagnostic test within a chosen factor, from the expected sensitivity, specificity and prevalence in a consecutive sample. Reports the expected reference-standard positives and negatives. Covers non-response.

    Engine version 1.0.0 · Reviewed 6 October 2026

    https://statwisely.com/methods/precision-likelihood-ratio/

    When to use it

    • A diagnostic-accuracy study reporting how much a positive or negative result changes the odds of disease.

    Not for

    • Sensitivity and specificity themselves, with margins in percentage points. Use the sensitivity and specificity planner.

    Notation

    Se, SpSe,\ Sp
    Expected sensitivity and specificity
    PrevPrev
    Expected prevalence
    LR+, LR−LR^{+},\ LR^{-}
    Positive and negative likelihood ratios, Se/(1 − Sp) and (1 − Se)/Sp
    ff
    Precision factor: the interval runs from LR / f to LR × f
    z1−α/2z_{1-\alpha/2}
    Standard normal quantile for confidence 1 − α (1.960 for 95%)
    qq
    Non-response rate

    Formulas

    Variances of the log likelihood ratios

    N=⌈z1−α/22 V(ln⁡f)2⌉,V+=1−SePrev Se+Sp(1−Prev)(1−Sp),V−=SePrev(1−Se)+1−Sp(1−Prev) SpN = \left\lceil \frac{z_{1-\alpha/2}^{2}\, V}{(\ln f)^{2}} \right\rceil, \quad V_{+} = \frac{1-Se}{Prev\,Se} + \frac{Sp}{(1-Prev)(1-Sp)}, \quad V_{-} = \frac{Se}{Prev(1-Se)} + \frac{1-Sp}{(1-Prev)\,Sp}

    The large-sample variances of ln LR+ and ln LR−, per person screened [1]. Planning both takes the larger. The interval is symmetric on the log scale, so the margin is a factor.

    Non-response

    napproach=⌈n1−q⌉n_{\text{approach}} = \left\lceil \frac{n}{1 - q} \right\rceil

    The number to approach so that n respond. Applied last, after any clustering.

    Parameters

    Confidence level1−α1-\alpha

    Values: 90%, 95% or 99%

    95% is the convention in health research. A higher level widens the interval, so the same margin needs a larger sample.

    Precision factorff

    Values: Above 1

    1.5 means the interval runs from LR / 1.5 to LR × 1.5.

    Expected sensitivitySeSe

    Values: Greater than 0 and less than 1

    A sensitivity close to 1 makes LR− hard to estimate.

    Expected specificitySpSp

    Values: Greater than 0 and less than 1

    A specificity close to 1 makes LR+ hard to estimate.

    Expected prevalencePrevPrev

    Values: Greater than 0 and less than 1

    In the people who will actually be tested. It splits the sample into reference-standard positives and negatives.

    Likelihood ratio to estimateLRLROptional

    Values: Positive, negative, or both

    Both plans for the harder of the two.

    Expected non-response rateqqOptional

    Values: 0% up to, but not including, 100%

    The share of people approached who will not take part; use the response rate of a comparable study. Approaching more people restores the number of respondents, not their representativeness: if non-responders differ, the estimate can still be biased.

    Assumptions

    • Participants are independent, sampled consecutively at the stated prevalence, and the reference standard is accurate.
    • Non-response is unrelated to the outcome.

    Worked examples

    Both ratios within a factor of 1.5

    Se 0.8, Sp 0.9, prevalence 0.2: LR+ = 8 and LR− = 0.22; LR− is the harder, so N = 471.

    Sample size: 471

    Open this example in the calculator

    LR+ only

    Planning only the positive likelihood ratio: N = 293.

    Sample size: 293

    Open this example in the calculator

    Within a factor of 2

    Both ratios within a factor of 2: N = 162.

    Sample size: 162

    Open this example in the calculator

    Validation

    • Every worked example on this page is recomputed by the StatWisely engine whenever the software is built. If a number or formula here stopped matching the calculator, the release would be stopped until this document was corrected.
    • Simulating 20,000 diagnostic samples in R gave median interval factors of 1.502 for LR+ at 293 people and 1.497 for LR− at 471, against a target of 1.5. An independent R evaluation of the variances reproduces the engine’s sizes.

    How to cite

    StatWisely. Sample size to estimate diagnostic likelihood ratios. Method document, engine version 1.0.0, reviewed 2026-10-06. https://statwisely.com/methods/precision-likelihood-ratio/

    Cite the original references for the formulas your design uses as well.

    References

    1. 1.Simel DL, Samsa GP, Matchar DB. Likelihood ratios with confidence: sample size estimation for diagnostic test studies. Journal of Clinical Epidemiology. 1991;44(8):763–770. doi:10.1016/0895-4356(91)90128-v