model-variable-selection: Selecting model variables

Description Usage Arguments Value Examples

Description

The output task allows to select model variables using a concise mini language. You can select variables by name or using one of the helper functions described below.

Overview of selection features

The selection of variables builds on the tidyselect package which implements a powerful variable selection language (see tidyselect::language). The following features are most relevant for the selection of model variables:

In addition, you can select variables using a combination of the following helper functions:

Usage

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11

Arguments

vars

A character vector of variable names (taken from the selection context)

match

A character vector to match against

Value

A selection context

Examples

1
2
3
4
5
6
7
8
9
m <- model() +
  input_variable("dose") +
  prm_log_normal("emax", median = 10, var_log = 0.09) +
  prm_log_normal("ed50", median = 50, var_log = 0.09) +
  algebraic(effect~emax*dose/(ed50 + dose)) +
  obs_proportional(~effect, var_prop = 1)

# output all model parameter and eta variables
render(m, tasks = tsk_output("prms", variables = vars_prms() | vars_eta()))

assemblerr documentation built on Jan. 13, 2022, 1:07 a.m.