CLAST-package {CLAST}R Documentation

Confidence Limits After Sequential Trial Exact Confidence Limits after a Sequential Trial


The user first provides design vectors n, a and b as well as null (p0) and alternative (p1) benchmark values for the probability of success. The key function "mv.plots.SM()" calculates mean values of exact upper and lower limits based on four different rank ordering methods. These plots form the basis of selecting a rank ordering. The function "inference()" calculates exact limits from a provided realisation and ordering choice. For more information, see "Exact confidence limits after a group sequential single arm binary trial" by Lloyd, C.J. (2020), Statistics in Medicine, Volume 38, 2389-2399, <doi:10.1002/sim.8909>.


This package allows the user to compare different methods of calculating exact upper and lower limits for a probability after a group sequential trial.


Chris J. Lloyd Maintainer: Chris J. Lloyd <>


Lloyd, C.J. (2020) Exact confidence limits after a group sequential single arm binary trial. Statistics in Medicine, Volume 38, 2389-2399. doi: 10.1002/sim.8909


# Example 1 in table 1 of Lloyd (2020)
  b=c(5,9,11,13),a,b) # Produces figure 1 in reference
  errors.SM(n,a,b,p0,p1) # Gives type 1 and type 2 errors,a,b,p0,p1) # Add error rates into plot title
# Selection of type of limits is based on the diagnostic plots
# from the next command, which produces three panel graphic
# identical to Figure 2 in the main reference. The results here
# support method LR
# Once we have an actual outcome we can calculate the limits.
  y=c(4,2,5) # Trial terminates on trial 2 since total successes is 11.
# Produces exact limits for specific outcome y.

[Package CLAST version 1.0.1 Index]