weights_mml {baskexact}R Documentation

Weights Based on the Marginal Maximum Likelihood

Description

Weights Based on the Marginal Maximum Likelihood

Usage

weights_mml(design, ...)

## S4 method for signature 'OneStageBasket'
weights_mml(
  design,
  n,
  prune = FALSE,
  lambda,
  globalweight_fun = NULL,
  globalweight_params = list(),
  ...
)

## S4 method for signature 'TwoStageBasket'
weights_mml(design, n, n1, ...)

Arguments

design

An object of class Basket created by setupOneStageBasket or setupTwoStageBasket.

...

Further arguments.

n

The sample size per basket.

prune

Whether baskets with a number of responses below the critical pooled value should be pruned before the final analysis. If this is TRUE then lambda is also required and if globalweight_fun is not NULL then globalweight_fun and globalweight_params are also used.

lambda

The posterior probability threshold. See details for more information.

globalweight_fun

Which function should be used to calculate the global weights.

globalweight_params

A list of tuning parameters specific to globalweight_fun.

n1

The sample size per basket for the interim analysis in case of a two-stage design.

Details

weights_mml calculates the weights based on the marginal maximum likelihood approach by Gravestock & Held (2017). In this approach, the weight is found as the maximum of the marginal likelihood of the weight-parameter given the dataset that information should be borrowed from. However, since this can lead to non-symmetric weights (meaning that the amount of information that data set 1 borrows from data set 2 is generally not identical to the information data set 2 borrows from data set 1), a symmetrised version is used here: For the sharing-weight of Basket 1 and Basket 2 the MML is calculted two times - once conditional on the data of Basket 1 and once conditional on the data of Basket 2. The mean of these two weights is then used, resulting in symmetrical sharing.

Value

A matrix including the weights of all possible pairwise outcomes.

Methods (by class)

References

Gravestock, I., & Held, L. (2017). Adaptive power priors with empirical Bayes for clinical trials. Pharmaceutical statistics, 16(5), 349-360.

Examples

design <- setupOneStageBasket(k = 3, p0 = 0.2)
toer(design, n = 15, lambda = 0.99, weight_fun = weights_mml)

[Package baskexact version 1.0.1 Index]