make_decisions {drugprepr} | R Documentation |
Human-friendly interface to the drug prep algorithm
Description
A helper function that allows specifying decision rules using English
words rather than alphanumeric codes. Translates the rules into the
corresponding codes and then passes them to drug_prep
functions.
Usage
make_decisions(
implausible_qty,
missing_qty,
implausible_ndd,
missing_ndd,
implausible_duration,
calculate_duration,
missing_duration,
clash_start,
overlapping,
small_gaps
)
Arguments
implausible_qty |
implausible total drug quantities |
missing_qty |
missing total drug quantities |
implausible_ndd |
implausible daily dosage |
missing_ndd |
missing daily dosage |
implausible_duration |
overly-long prescription durations |
calculate_duration |
formula or variable to compute prescription duration |
missing_duration |
missing prescription duration |
clash_start |
how to disambiguate prescriptions that start on the same date |
overlapping |
how to handle prescription periods that overlap with one another |
small_gaps |
how to handle short gaps between successive prescriptions The argument
|
Value
A character vector suitable for passing to the decisions
argument of
the drug_prep
function.
Examples
make_decisions('ignore',
'mean population',
'missing',
'mean practice',
'truncate 6',
'qty / ndd',
'mean individual',
'mean',
'allow',
'close 15')