Learn R Programming

RSurveillance (version 0.2.1)

spp: Population specificity

Description

Calculates population specificity assuming representative sampling

Usage

spp(n, sp)

Arguments

n

sample size (number tested), integer, scalar or vector

sp

unit specificity of test (proportion), scalar or vector of same length as n

Value

a vector of population-level specificities

Examples

Run this code
# NOT RUN {
# examples for spp - checked
spp(10, 0.9)
spp(c(10, 20, 50, 100), 0.99)
spp(100, c(0.999, 0.99, 0.98, 0.95, 0.9))
# }

Run the code above in your browser using DataLab