PMAP Comorbidity Info Feature Engineering

Created: January 6, 2023\ Last Modified: January 23, 2023

This notebook generates binary flags of Elixhauser comorbidity information of CHF hospital stays w/ ICU.\ Reference for the ICD-10 coding algorithm for Elixhauser comorbidities are from the Agency for Healthcare Research and Quality (AHRQ).

Author: Vina Ro

Data Cleaning

1. Elixhauser References from AHRQ

2. Concatenate all diagnosis information(icd10 codes) from 3 dataframes into 1, and drop rows w/ missing icd10 codes

enc_dx + prob_list + hosp_billing -> df_all_icd10

Feature Engineering

Data Visualization

1. Prevalence of Elixhauser Comorbidities in our cohort

Appendix

1. Elixhauser

The below are functions that generate elixhauser and charlson comorbidities from ICD-10 codes via Regex.\ *per discussion w/ Dr. F (01/19/23): This uses an outdated version of elixhauser.

2. Calculate Elixhauser Comorbidity Scores

Using the van Walraven algorithm (range -19 [less likely for in-hospital death] to 89 [more likely for in-hospital death]) to calculate scores from the Elixhauser Comorbidity Index.\ *per discussion w/ Dr. F (01/19/23): scoring system is devloped from elixhauser w/ ICD-9 codes and should be deleted since it may lose predictive value.