R/efftox_parse_outcomes.R
efftox_parse_outcomes.Rd
Parse a string of EffTox outcomes to the binary vector notation
required by Stan for model invocation. The outcome string describes the doses
given and outcomes observed. The format of the string is described in Brock
et al. (2017). The letters E, T, N and B are used to represents patients that
experienced (E)fficacy only, (T)oxicity only, (B)oth efficacy and toxicity,
and (N)either. These letters are concatenated after numerical dose-levels to
convey the outcomes of cohorts of patients. For instance, 2ETB
represents a cohort of three patients that were treated at dose-level 2, and
experienced efficacy, toxicity and both events, respectively. The results of
cohorts are separated by spaces. Thus, 2ETB 1NN
extends our previous
example, where the next cohort of two were treated at dose-level 1 and both
patients experienced neither efficacy nor toxicity. See examples.
We present the notation in the EffTox setting but it is applicable in general seamless phase I/II dose-finding scenarios.
efftox_parse_outcomes(outcome_string, as.list = TRUE)
outcome_string | character string, conveying doses given and outcomes observed. |
---|---|
as.list | TRUE (be default) to return a |
If as.list == TRUE
, a list with elements eff
, tox
,
doses
and num_patients
. These elements are congruent with those
of the same name in efftox_params
.
If as.list == FALSE
, a data.frame with columns eff
, tox
,
and doses
.
Brock, K., Billingham, L., Copland, M., Siddique, S., Sirovica, M., & Yap, C. (2017). Implementing the EffTox dose-finding design in the Matchpoint trial. BMC Medical Research Methodology, 17(1), 112. https://doi.org/10.1186/s12874-017-0381-x
x = efftox_parse_outcomes('1NNE 2EEN 3TBB') x$num_patients == 9#> [1] TRUE#> [1] TRUE TRUE TRUE TRUE TRUE TRUE TRUE TRUE TRUE#> [1] TRUE