interim_postpred {baskexact}R Documentation

Interim analysis based on the posterior predictive probability

Description

Conducts an interim analysis based on the posterior predictive probability.

Usage

interim_postpred(design, ...)

## S4 method for signature 'TwoStageBasket'
interim_postpred(
  design,
  n,
  n1,
  r1,
  lambda,
  weight_mat,
  globalweight_fun = NULL,
  globalweight_params,
  prob_futstop = 0.1,
  prob_effstop = 0.9,
  ...
)

Arguments

design

An object of class Basket created by setupOneStageBasket or setupTwoStageBasket.

...

Further arguments.

n

The sample size per basket.

n1

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

r1

Vector of responses after the interim analysis.

lambda

The posterior probability threshold. See details for more information.

weight_mat

The matrix with all weights. Automatically calculated in the functions to which interim_postpred is passed.

globalweight_fun

Which function should be used to calculate the global weights.

globalweight_params

A list of tuning parameters specific to globalweight_fun.

prob_futstop

Probability cut-off for stopping for futility.

prob_effstop

Probability cut-off for stopping for efficacy.

Details

interim_postpred conducts an interim analysis with possible stop for efficacy and futility based on the posterior predictive probability. If the posterior predictive probability is less than prob_fustop the basket is stopped for futility, if the posterior predictive probability is greater than prob_effstop the basket is stopped for efficacy. If prob_fustop = 0 or prob_effstop = 1 then no futility-stop and no efficacy stop is possible, respectively.

The function is generally not called by the user but passed to another function such as toer and pow to specify which interim analysis is conducted.

Value

A vector with a length equal to the number of baskets with elements -1, 0 or 1 where -1 means stop for futility, 0 means continuation and 1 means stop for efficacy.

Methods (by class)

Examples

design <- setupTwoStageBasket(k = 3, p0 = 0.2)
toer(design, n = 20, n1 = 10, lambda = 0.99, interim_fun = interim_postpred,
  weight_fun = weights_fujikawa)

[Package baskexact version 1.0.1 Index]