icd_classes_conflict: Check whether there are any ICD class conflicts

Description Usage Arguments Examples

View source: R/class.R

Description

Some classes cannot be simultaneously true for one vector of ICD codes, e.g. ICD-9-CM and ICD-9 from the WHO. This function returns TRUE if there are any such combinations of incompatible classes. If the constructor functions such as icd9cm() and icd10() are used, this should never happen.

Usage

1

Arguments

x

input object to test for class conflicts

Examples

1
2
3
bad_codes <- c("100", "A01", "V100", "E999.0")
class(bad_codes) <- c("icd9", "icd10cm")
stopifnot(icd:::icd_classes_conflict(bad_codes))

icd documentation built on June 8, 2018, 1:04 a.m.