Learn R Programming

basksim (version 2.0.2)

get_evaluation.bhm: Evaluate a BHM Basket Trial

Description

Evaluate a BHM Basket Trial

Usage

# S3 method for bhm
get_evaluation(
  design,
  n,
  r,
  lambda,
  level = 0.95,
  tau_scale,
  n_mcmc = 10000,
  ...
)

Value

A list containing the point estimates of the basket-specific response rates.

Arguments

design

An object of class bhm.

n

The sample sizes of the baskets. A vector must be used for varying sample sizes.

r

Vector of responses.

lambda

The posterior probability threshold.

level

Level of the credibility intervals.

tau_scale

Standard deviation of the half normal prior distribution for the variance of the thetas.

n_mcmc

Number of MCMC samples.

...

Further arguments.

Examples

Run this code
design <- setup_bhm(k = 3, p0 = 0.2, p_target = 0.5)

get_evaluation(design = design, n = c(20, 20, 20), r = c(10, 15, 5),
  lambda = 0.95, tau_scale = 1, iter = 100)

# Unequal sample sizes
get_evaluation(design = design, n = c(15, 20, 25), r = c(10, 15, 17),
  lambda = 0.95, tau_scale = 1, iter = 100)

Run the code above in your browser using DataLab