Calculate Charlson scores from precomputed Charlson comorbidities, instead of directly from the ICD codes. This is useful if the comorbidity calculation is time consuming. Commonly, both the Charlson comorbidities and the Charlson scores will be calculated, and this function provides just that second step.
1 2 3 4 5 6 | charlson_from_comorbid(
x,
visit_name = NULL,
hierarchy = FALSE,
scoring_system = c("original", "charlson", "quan")
)
|
x |
data.frame or matrix, typically the output of a comorbidity
calculation which uses the Charlson categories, e.g.
|
visit_name |
The name of the column in the data frame which contains the
patient or visit identifier. Typically this is the visit identifier, since
patients come leave and enter hospital with different ICD-9 codes. It is a
character vector of length one. If left empty, or |
hierarchy |
single logical value, default is |
scoring_system |
One of |
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.