getRxCuiViaNDC: Get RxCui via U.S National Drug Code(NDC)

View source: R/getRxCuiViaNDC.R

getRxCuiViaNDCR Documentation

Get RxCui via U.S National Drug Code(NDC)

Description

This is a function to get RxCui via National Drug Code(NDC)

Usage

getRxCuiViaNDC(df, NdcColName = NDC, cores = 8)

Arguments

df

data.frame, a drug ingredient's NDC of the specific indication

NdcColName

a column name for NDC of df

cores

number of parallel operation

Details

User can input the data.frame with drug column which encoded in NDC. The content is to add a column named RxCui in the original input data frame, storing the result of converting NDC to RxNorm in this column. The column ndcStatus is to show whether the converted NDC is now used.

Value

A new data.table sample_data_subset_rxcui with following columns.

MemberId patient Id

DispenseDate patient's drug dispensed date, and the time interval is from 2025-12-06 to 2038-01-25

NationalDrugCode drug NDC, total of 17,326 different drug codes

Quantity quantity of patient's drug dispensed

DaysSupply days of patient's drug dispensed

RxCui drug code for the drug in the RxNorm drug vocabulary

ndcStatus NDC status

Examples

#sample of getting RxCui via NDC.
sample_data_subset_rxcui <- getRxCuiViaNDC(df = sample_data_subset, NdcColName = NationalDrugCode)
head(sample_data_subset_rxcui)

DHLab-CGU/pharm documentation built on July 2, 2022, 7:16 a.m.