Description Usage Arguments Value
Labels ICD 8 and 10 codes based on Elixhauser, Charlson and custom categories by taking a column of ICD08/09/10 diagnoses and mapping those to Elixhauser, Charlson or a third custom defined grouping (can be overwritten)
1 | encode.icd(data, diag.col, types = c("elixh", "charl", "custm"), comorbs)
|
data |
a data frame containing a column with ICD-codes. 10 and 08/09 are accepted. |
diag.col |
name of column in data frame, that contains ICD codes. ICD10 codes should have a 'D' prefix. |
types |
takes a character vector as input, containing one or more of the following values: 'elixh', 'charl' and 'custm'. |
comorbs |
is a list corresponding to the output of the 'comorbs' function. It maks diagnoses to diagnosis groups |
the function returns the input dataframe, but adding the columns corresponding to each diagnosis group defined in the Elixhauser, Charlson or custom definitions.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.