computeAlphaLevel {GroupSeq}R Documentation

Computes alpha level and other probabilities

Description

Computes alpha level and other probabilities for the number of tests of hypotheses. Method is a modification of Armitage, McPherson and Rowe. Consistent with Lan & DeMets 83, does not assume equally spaced information times.

Usage

computeAlphaLevel(n, t, t2, lowerBounds, upperBounds, drift, nMax)

Arguments

n the number of analyses
t the vector of analysis time point on (0,1).
t2 is the second or information time scale, for covariances
lowerBounds the vector of upper bounds (standardized)
upperBounds the vector of lower bounds (standardized)
drift the noncentrality; at t=1, process has mean drift.
nMax Number of interim analyses is limited to nMax=25.

Value

probStopping(i) is the prob of reaching ith analysis and stopping.
probExceedingUpper(i) is the prob of reaching ith and exceeding upper.
probExceedingLower(i) is the prob of reaching ith and exceeding lower.
expectedStoppingTime is expected stopping time (not implemented).
probTotal is the total type I error used.

Note

This function is meant to be called in context of using groupseq

Author(s)

Roman Pahl

References

Armitage, McPherson & Rowe 1969 JRSSA
Lan & DeMets 1983 Biometrika http://www.biostat.wisc.edu/landemets/

See Also

groupseq, stdDeviations pnorm, jointDensity

Examples

## fictious example 
computeAlphaLevel(3, c(0.33,0.66,1),c(0.33,0.66,1), c(-1,0,1), c(2,3,4),0.2, 25)
## with following result:
#  $probAndStop
# [1] 0.1621561 1.0000000 1.0000000
#
# $probAndExceedingUpper
# [1] 2.970758e-02 7.447682e-04 9.675729e-06
#
# $probAndExceedingLower
# [1] 0.1324485 0.3115237 0.3327052
#
# $expectedStoppingTime
# [1] 0
#
# $totalTypeOneError
# [1] 0.8071395
#

[Package GroupSeq version 1.0 Index]