tidy_meds_sched: Tidy scheduled medications

Description Usage Arguments Details Value

Description

tidy_meds_sched determines which patients have the desired medications

Usage

1
tidy_meds_sched(raw.data, ref.data)

Arguments

raw.data

A data frame with all scheduled medications

ref.data

A data frame with three columns: name, type, and group

Details

This function takes a data frame with reference medications or medication classes and a data frames with all scheduled medications, and returns a data frame with only the desired medications for each patient. The data frame passed to ref.data should contain three columns: name, type, and group. The name column should contain either generic medication names or medication classes. The type column should specify whether the value in name is a "class" or "med". The group column should specify whether the medication is a continous or scheduled medication.

Value

A data frame


bgulbis/BGTools documentation built on May 12, 2019, 8:21 p.m.