Sets the arguments external_t and external_c of a design
specification started by qdm_endpoint: external data of the
treatment and control groups, borrowed through a power prior. With
n_c = 0 (see qdm_sample_size) and external control
data, the control group is the external control data only. The arguments
are checked when the design is built, by the design_*() function of
the endpoint. All the arguments of the step are set together: an argument
that is not given returns to the default, so
qdm_external(x, external_c = ...) also removes the external data of
the treatment group of x.
Arguments
- x
A design specification started by
qdm_endpoint, or a design, which is converted to the specification that builds it.- external_t, external_c
External data of the treatment and control groups, created by
borrowwith thedata_*()function of the endpoint, orNULL(no external data).
See also
Other design steps:
qdm_build(),
qdm_computation(),
qdm_control(),
qdm_criterion(),
qdm_endpoint(),
qdm_prior(),
qdm_sample_size(),
qdm_tte()
Examples
qdm_endpoint("binary") |>
qdm_external(external_c = borrow(data_binary(n = 20, y = 8), a0 = 0.5))
#> Design specification: one binary endpoint (incomplete)
#> Arguments set: external_c
#> Still needed: the sample sizes (qdm_sample_size()), the prior distributions (qdm_prior()), the decision criterion (qdm_criterion())
