Become an expert in R — Interactive courses, Cheat Sheets, certificates and more!
Get Started for Free

get_random_selector

Get an object to fit a dose-selector that randomly selects doses.


Description

Get an object to fit a dose-selector that randomly selects doses. Whilst this design is unlikely to pass the ethical hurdles when investigating truly experimental treatments, this class is useful for illustrating methods and can be useful for benchmarking.

Usage

get_random_selector(
  parent_selector_factory = NULL,
  prob_select,
  supports_efficacy = FALSE,
  ...
)

Arguments

parent_selector_factory

optional object of type selector_factory that is in charge of dose selection before this class gets involved. Leave as NULL to just select random doses from the start.

prob_select

vector of probabilities, the probability of selecting dose 1...n

supports_efficacy

TRUE to monitor toxicity and efficacy outcomes; FALSE (by default) to just monitor toxicity outcomes.

...

Extra args are ignored.

Value

an object of type selector_factory.

Examples

prob_select = c(0.1, 0.3, 0.5, 0.07, 0.03)
model <- get_random_selector(prob_select = prob_select)
fit <- model %>% fit('1NTN')
fit %>% recommended_dose() # This is random
# We could also precede this selector with a set path:
model <- follow_path('1NN 2NN 3NN') %>%
  get_random_selector(prob_select = prob_select)
fit <- model %>% fit('1NN')
fit %>% recommended_dose() # This is not-random; it comes from the path.
fit <- model %>% fit('1NN 2NT')
fit %>% recommended_dose() # This is random; the path is discarded.

escalation

Modular Approach to Dose Finding Clinical Trials

v0.1.4
GPL (>= 3)
Authors
Kristian Brock [aut, cre] (<https://orcid.org/0000-0002-3921-0166>)
Initial release
2020-10-16

We don't support your browser anymore

Please choose more modern alternatives, such as Google Chrome or Mozilla Firefox.