Skip to contents

Match spellings of a route of administration to the route PKNCA uses

Usage

pknca_match_route(x)

Arguments

x

A character vector (or factor) of route spellings, such as "PO" or "INTRAVENOUS BOLUS". Matching ignores case and leading, trailing, and repeated white space.

Value

A data.frame with one row for each element of x and the columns route (one of pknca_routes(), or "iv" when the spelling is intravascular but does not say which intravascular route it is) and dose_route ("extravascular" or "intravascular", the values PKNCAdose() accepts for route). Both are NA when the spelling is not known or x is NA.

Examples

pknca_match_route(c("PO", "Intravenous", "IV BOLUS", "unknown"))
#>           route    dose_route
#> 1 extravascular extravascular
#> 2            iv intravascular
#> 3      iv_bolus intravascular
#> 4          <NA>          <NA>