Creates the design specified step by step from qdm_endpoint,
by calling the design_*() function of the endpoint
(design_binary, design_continuous,
design_binary2, design_continuous2 or
design_tte) with the arguments set. The design is identical
to the one created by calling that function directly with the same
arguments, and invalid arguments give the same errors. The sample sizes
(qdm_sample_size), the prior distribution of the treatment
group (qdm_prior) and the decision criterion
(qdm_criterion) must have been set.
Arguments
- x
A design specification started by
qdm_endpoint, or a design, for which the same design is returned.
Value
A design, an object of class "qdm_design", as returned by
the design_*() function of the endpoint.
See also
Other design steps:
qdm_computation(),
qdm_control(),
qdm_criterion(),
qdm_endpoint(),
qdm_external(),
qdm_prior(),
qdm_sample_size(),
qdm_tte()
Examples
qdm_endpoint("binary") |>
qdm_sample_size(n_t = 12, n_c = 12) |>
qdm_prior(prior_t = prior_beta(0.5, 0.5),
prior_c = prior_beta(0.5, 0.5)) |>
qdm_criterion(criterion_posterior(theta_tv = 0.2, theta_mav = 0.1,
gamma_go = 0.5, gamma_nogo = 0.8)) |>
qdm_build()
#> Design: one binary endpoint
#> Treatment: n = 12, prior Beta(a = 0.5, b = 0.5)
#> Control: concurrent, n = 12, prior Beta(a = 0.5, b = 0.5)
#> Posterior probability criterion
#> Go: P(theta > 0.2 | data) >= 0.5
#> NoGo: P(theta <= 0.1 | data) >= 0.8
