Decision | R Documentation |
Maps the statistical results at an interim, decision or final analysis into a decision regarding whether to stop recruitment (interim) or whether to reject the null hypothesis (decision/final). Stopping boundaries are updated based on observed information and correct p-values, confidence intervals and point estimates are given.
Decision(object, k, type.k, PositiveIsGood = TRUE, trace = TRUE)
object |
object of class |
k |
[integer] index of the analysis. |
type.k |
[character] type of analysis: |
PositiveIsGood |
[logical] whether a positive effect is considered beneficial (TRUE/FALSE) |
trace |
[logical] should the execution of the function be traced? |
Function that maps the statistical results at interim (or final) analysis into decision to reject, or continue or stop inclusind subjects.
ff
Paul Blanche
#### Planning #####
theAlpha <- 0.025
theBeta <- 0.2
theDelta <- 1.5
theK <- 2
theN <- 82
myBound0 <- CalcBoundaries(kMax=theK,
sided=1,
alpha=theAlpha,
beta=theBeta,
InfoR.i=c(0.5,1),
rho_alpha=2,
rho_beta=2,
method=1,
delta=theDelta,
InfoR.d=0.55)
#### Simulate data ####
## generate data with all data for in case trial completes
set.seed(10)
theData <- GenData(n=theN*2,delta=theDelta*0.8,ar=5)
theAR <- 10 #accrual rate (pt per month)
theDelay <- 0.7500001 #time in months to process data
tau.i <- theData$d$t3[theN + ceiling(theAR*theDelay)] #time point at which to do IA
theObsData <- SelectData(theData$d, t = tau.i, Delta.t = theDelay)
#### Analyse data at interim ####
myLMM <- analyzeData(theObsData)
myBound1 <- updateBoundaries(myBound0, lmm = myLMM, k = 1, type.k = "interim")
myInterim1 <- Decision(myBound1, k = 1, type.k = "interim")
myInterim1$conclusion
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.