R: Create Quan map of ICD-9-CM to Charlson comorbidities
icd9cm_charlson_quan
R Documentation
Create Quan map of ICD-9-CM to Charlson comorbidities
Description
Function that creates a dataframe that links ICD-9-CM codes to the Charlson comorbidity
categories using Quan's method.
Usage
icd9cm_charlson_quan(icd9)
Arguments
icd9
a unique character vector of ICD-9-CM codes
Details
NOTE: The input vector of ICD-9-CM codes must be unique, because the output dataframe
uses the ICD-9-CM code as row.name.
Uses regular expressions created from the paper by Quan in 2005.
ICD-9-CM codes must have periods removed. Diagnostic codes are prefixed with
'D' while procedure codes are prefixed with 'P'. So, diagnostic code
404.03 should be "D40403".
Value
A data frame, with ICD9 codes as row names and one logical column for each
comorbidity in charlson_list
References
1. Quan H, Sundararajan V, Halfon P, Fong A, Burnand B, Luthi
J-C, Saunders LD, Beck CA, Feasby TE, Ghali WA: Coding algorithms for
defining comorbidities in ICD-9-CM and ICD-10 administrative data. Medical
care 2005; 43:1130-9
http://www.ncbi.nlm.nih.gov/pubmed/16224307