classify_ccsr_dx1: Classify principal diagnosis into CCSR category

View source: R/ccsr_dx.R

classify_ccsr_dx1R Documentation

Classify principal diagnosis into CCSR category

Description

Converts a vector of ICD-10 principal diagnosis codes to the default Clinical Classifications Software Refined (CCSR) category based on the inpatient or outpatient setting

Usage

classify_ccsr_dx1(icd_10_dx1, setting = NULL)

Arguments

icd_10_dx1

A vector of principal ICD diagnosis codes (without decimals)

setting

Either "inpatient", (default) or "outpatient" Note that this single default CCSR category only applies to the principal diagnosis (for inpatient) and first-listed diagnosis (for outpatient). These can also be abbreviated as "ip" or "op".

Details

The Clinical Classifications Software Refined (CCSR) software provides both one-to-one mapping (see classify_ccsr_dx1) and one-to-many (see ccsr_dx) mapping of ICD-10-CM diagnosis codes to CCSR categories. The one-to-many mapping is necessary because many ICD-10 codes span multiple meaningful categories, and the identification of all conditions related to a diagnosis code would be lost by categorizing some ICD-10-CM codes into a single category.

For example, consider the code I11.0 (Hypertensive heart disease with heart failure) which encompasses both heart failure (CCSR category CIR019) and hypertension with complications (CIR008). Classifying this code as heart failure alone would miss meaningful information, but on the other hand, some analyses require mutually exclusive categorization.

CCSR accomplishes this by providing a "default" CCSR category based on the principal diagnosis (for inpatient data) and the first-listed diagnosis (for outpatient data); see page 16 of the CCSR DX user guide for details.

This function addresses identifying the default CCSR category based on the principal/first-listed diagnosis. For applications utilizing all ICD-10-CM codes, such as risk adjustment and identification of comorbidities, please use the ccsr_dx function.

Value

A vector of the default CCSR categories

See Also

ccsr_dx for identifying all CCSR categories in a non-mutually exclusive method

Examples

classify_ccsr_dx1("I110", setting = "inpatient")

library(dplyr)
dplyr::tibble(ICD10 = c("G4730", "L563", "A001")) %>%
  mutate(CCSR_ip = classify_ccsr_dx1(ICD10, setting="inpatient"),
         CCSR_op = classify_ccsr_dx1(ICD10, setting="outpatient"))

HunterRatliff1/hcup documentation built on Aug. 6, 2023, 6:10 p.m.