Skip to contents

A case is open, meaning still awaiting classification, when POLIS has not written a final classification for it. That is the case when the classification field is missing or blank, or when it holds one of the pending labels in pending_classes. Labels are matched after trimming white space and ignoring case.

Usage

afp_pending_open(classification, pending_classes = c("PENDING", "LAB PENDING"))

Arguments

classification

A vector of case classifications, for example the classification_all column of a cleaned AFP table.

pending_classes

Classification labels that mean the case is still pending. The default, c("PENDING", "LAB PENDING"), is the programme standard and matches calc_polio_indicators().

Value

A logical vector the length of classification, TRUE where the case is open. It is never NA.

See also

calc_pending_stage() for the table built on this flag.

Examples

afp_pending_open(c("NPAFP", "PENDING", "", NA, "Lab Pending", "WPV1"))
#> [1] FALSE  TRUE  TRUE  TRUE  TRUE FALSE