preproc.code.splitter: Code splitter

Description Usage Arguments Value See Also Examples

View source: R/peprocessors.R

Description

As the number of codes per admission frequently may differs between visits and patients it can be efficient to store them in a string that is separated by a " " character os something similar. In case you want something other than a space you need to encapsulate the function.

Usage

1
preproc.code.splitter(icd, icd_ver, split_str = " ", trim = TRUE)

Arguments

icd

The ICD-codes to be stripped

icd_ver

Currently not used - this parameter is only for compatibility reasons as other preprocessing functions may require the knowledge of actual icd version.

split_str

The string that is the splitter

trim

If the string has trailing spaces these should usualy be removed

Value

vector A vector with only one code per entry. The attr(,"icd_ver") now contains the corresponding icd_version.

See Also

Other preprocessor functions: preproc.Swedich.ICD9; preproc.strip.dot

Examples

1
2
preproc.code.splitter(icd=c("M161", "M161 ", "M161 J445"),
                  icd_ver=c(10, 10, 10))

gforge/comorbidities.icd10 documentation built on May 17, 2019, 2:12 a.m.