Learn R Programming

AGSDest (version 2.3.4)

AGSTobj: Adaptive group sequential trial object (AGSTobj)

Description

The AGSTobj includes design and outcome of primary and secondary trial.

Usage

AGSTobj(x, ...)

# S3 method for AGSTobj plot(x, main = c("primary trial", "secondary trial"), print.pdf = FALSE, ...)

# S3 method for AGSTobj print(x, ...)

# S3 method for AGSTobj summary(object, ctype = c("r", "so"), ptype = c("r", "so"), etype = c("ml", "mu", "cons"), overwrite = FALSE, ...)

# S3 method for summary.AGSTobj print(x, ...)

Arguments

x

object of the class AGSTobj

...

additional arguments.

main

Title of the plots (default: first plot: "primary trial"; second plot: "secondary trial")

print.pdf

option; if TRUE a pdf file is created. Instead of setting print.pdf to TRUE, the user can specify a character string giving the name or the path of the file.

object

object of the class AGSTobj

ctype

confidence type: repeated "r" or stage-wise ordering "so" (default: c("r", "so"))

ptype

p-value type: repeated "r" or stage-wise ordering "so" (default: c("r", "so"))

etype

point estimate: maximum likelihood "ml", median unbiased "mu", or conservative "cons" (default: c("ml", "mu", "cons"))

overwrite

option; if TRUE all old values are deleted and new values are calculated (default: FALSE)

Value

An object of class AGSTobj, which is basically a list with the elements

cb.so

confidence bound based on the stage-wise ordering (stage-wise adjusted confidence bound)

cb.r

repeated confidence bound

pvalue.so

p-value based on the stage-wise ordering (stage-wise adjusted p-value)

pvalue.r

repeated p-value

est.ml

maximum likelihood estimate

est.mu

median unbiased point estimate

est.cons

conservative point estimate

pT

K

number of stages

al

alpha (type I error rate)

a

lower critical bounds of primary group sequential design (are currently always set to -8)

b

upper critical bounds of primary group sequential design

t

vector with cumulative information fraction

SF

spending function (for details see below)

phi

parameter of spending function when SF=3 or 4 (for details see below)

alab

alpha-absorbing parameter values of primary group sequential design

als

alpha-values ''spent'' at each stage of primary group sequential design

Imax

maximum information number

delta

effect size used for planning the primary trial

cp

conditional power for planning the primary trial

iD

L

stage of the adaptation

z

z-statistic at adaptive interim analysis

sT

K

number of stages

al

conditional rejection probability

a

lower critical bounds of secondary group sequential design (are currently always set to -8)

b

upper critical bounds of secondary group sequential design

t

vector with cumulative information fraction

SF

spending function (for details see below)

phi

parameter of spending function when SF=3 or 4 (for details see below)

Imax

maximum information number

delta

effect size used for planning the secondary trial

cp

conditional power for planning the secondary trial

sTo

T

stage where trial stops

z

z-statistic at stage where trial stops

Details

A AGSTobj object is designed.

The function summary returns an object of class AGSTobj. ctype defines the type of confidence interval that is calculated.

"r" Repeated confidence bound for a GSD with design adaptations
"so" Confidence bound for a GSD with design adaptation based on the stage-wise ordering

The calculated confidence bounds are saved as:

cb.r repeated confidence bound
cb.so confidence bound based on the stage-wise ordering

ptype defines the type of p-value that is calculated.

"r" Repeated p-value for a GSD with design adaptations
"so" Stage-wise adjusted p-value for a GSD with design adaptations

The calculated p-values are saved as:

pvalue.r repeated p-value
pvalue.so stage-wise adjusted p-value

etype defines the type of point estimate

"ml" maximum likelihood estimate (ignoring the sequential and adaptive nature of the design)
"mu" median unbiased estimate (stage-wise lower confidence bound at level 0.5) for a GSD with design adaptations
"cons" conservative estimate (repeated lower confidence bound at level 0.5) for a GSD with design adaptations

The calculated point estimates are saved as:

est.ml Maximum likelihood estimate
est.mu Median unbiased estimate
est.cons Conservative estimate

The stage-wise adjusted confidence bound, p-value and the median unbiased point estimate can only be calculated at the stage where the trial stops and are only valid if the stopping rule is met.

The repeated confidence bound, repeated p-value, conservative estimate and maximum likelihood estimate can be calculated at every stage of the trial and not just at the stage where the trial stops and are also valid if the stopping rule is not met. For calculating the repeated confidence bounds or p-values the user has to specify sTo (secondary trial outcome) in the object AGSTobj (see example below). If the stopping rule is not met in object sTo then sta e-wise adjusted confidence bounds and p-values will not be computed while a warning message is given when their computation have erroneously been specified.

See Also

AGSTobj, print.AGSTobj, plot.AGSTobj, summary.AGSTobj

Examples

Run this code
# NOT RUN {
pT=plan.GST(K=3,SF=4,phi=-4,alpha=0.05,delta=6,pow=0.9,compute.alab=TRUE,compute.als=TRUE)

iD=list(T=1, z=1.090728)

swImax=0.0625

I2min=3*swImax
I2max=3*swImax

sT=adapt(pT=pT,iD=iD,SF=1,phi=0,cp=0.8,theta=5,I2min,I2max,swImax)

sTo=list(T=2, z=2.393)

AGST<-as.AGST(pT=pT,iD=iD,sT=sT,sTo=sTo)
AGST
plot(AGST)

AGST<-summary(AGST)
plot(AGST)

##The repeated confidence interval and p-value at an earlier stage
##than the one where the trial stops (T=3).

summary(as.AGST(pT,iD,sT,sTo=list(T=1,z=1.7)),ctype="r",ptype="r")

##If the stage-wise adjusted confidence interval is calculated at this stage,
##the function returns an error message
summary(as.AGST(pT,iD,sT,sTo=list(T=1,z=1.7)),ctype="so",ptype="so")
# }

Run the code above in your browser using DataLab