removex: Remove the x from an ICD-9 code string

Description Usage Arguments Value Examples

Description

Given a character string that represents an ICD-9 code or a range of codes, removex() removes the x in the string and returns a code or a code range that be used directly as input of getICD10().

Usage

1
removex(string)

Arguments

string

A vector of character strings, may or may not contain characters 'x' and '-'.

Value

A vector of character strings. Each string only contain numeric characters, and is either a complete ICD-9 code or the first few digits of an ICD-9 code that represents all codes starting with the same substring.

Examples

1
2
removex(c("7213", "7213x", "14xx-208xx"))
removex("015xx-12xxx")

songxh0424/MPrOVE-package documentation built on May 19, 2019, 4:18 p.m.