pad_3char_codes: Pad ICD-9 codes that do not have a sub-code (i.e.,...

View source: R/pad_3char_codes.R

pad_3char_codesR Documentation

Pad ICD-9 codes that do not have a sub-code (i.e., 3-character codes)

Description

Some of the ICD-9 codes only contain 3 characters (i.e., they do not contain subcodes). This function just takes the UCOD column and converts all of these 3 character codes into 4 by padding a zero at the end.

Usage

pad_3char_codes(icd9_ucod)

Arguments

icd9_ucod

The ucod column from an ICD-9 dataframe

Value

vector

Examples

pad_3char_codes(c("400", "4043", "304", "5062"))

mkiang/narcan documentation built on Sept. 26, 2024, 7:18 a.m.