getConditionalPower {rpact} R Documentation

## Get Conditional Power

### Description

Calculates and returns the conditional power.

### Usage

getConditionalPower(stageResults, ..., nPlanned, allocationRatioPlanned = 1)


### Arguments

 stageResults The results at given stage, obtained from getStageResults(). ... Further (optional) arguments to be passed: thetaH1 and assumedStDevs or piTreatments, piControlThe assumed effect size or assumed rates to calculate the conditional power in multi-arm trials or enrichment designs. For survival designs, thetaH1 refers to the hazard ratio. You can specify a value or a vector with elements referring to the treatment arms or the sub-populations, respectively. For testing means, an assumed standard deviation can be specified, default is 1. iterationsIterations for simulating the power for Fisher's combination test. If the power for more than one remaining stages is to be determined for Fisher's combination test, it is estimated via simulation with specified iterations, the default value is 10000. seedSeed for simulating the power for Fisher's combination test. See above, default is a random seed. nPlanned The additional (i.e., "new" and not cumulative) sample size planned for each of the subsequent stages. The argument must be a vector with length equal to the number of remaining stages and contain the combined sample size from both treatment groups if two groups are considered. For survival outcomes, it should contain the planned number of additional events. For multi-arm designs, it is the per-comparison (combined) sample size. For enrichment designs, it is the (combined) sample size for the considered sub-population. allocationRatioPlanned The planned allocation ratio n1 / n2 for a two treatment groups design, default is 1. For multi-arm designs, it is the allocation ratio relating the active arm(s) to the control.

### Details

The conditional power is calculated only if the effect size and the sample size is specified.

For Fisher's combination test, the conditional power for more than one remaining stages is estimated via simulation.

### Value

Returns a ConditionalPowerResults object. The following generics (R generic functions) are available for this result object:

• names() to obtain the field names,

• print() to print the object,

• summary() to display a summary of the object,

• plot() to plot the object,

• as.data.frame() to coerce the object to a data.frame,

• as.matrix() to coerce the object to a matrix.

### How to get help for generic functions

Click on the link of a generic in the list above to go directly to the help documentation of the rpact specific implementation of the generic. Note that you can use the R function methods to get all the methods of a generic and to identify the object specific name of it, e.g., use methods("plot") to get all the methods for the plot generic. There you can find, e.g., plot.AnalysisResults and obtain the specific help documentation linked above by typing ?plot.AnalysisResults.

plot.StageResults() or plot.AnalysisResults() for plotting the conditional power.

Other analysis functions: getAnalysisResults(), getClosedCombinationTestResults(), getClosedConditionalDunnettTestResults(), getConditionalRejectionProbabilities(), getFinalConfidenceInterval(), getFinalPValue(), getRepeatedConfidenceIntervals(), getRepeatedPValues(), getStageResults(), getTestActions()

### Examples


data <- getDataset(
n1     = c(22, 13, 22, 13),
n2     = c(22, 11, 22, 11),
means1 = c(1, 1.1, 1, 1),
means2 = c(1.4, 1.5, 1, 2.5),
stds1  = c(1, 2, 2, 1.3),
stds2  = c(1, 2, 2, 1.3))
stageResults <- getStageResults(
getDesignGroupSequential(kMax = 4),
dataInput = data, stage = 2, directionUpper = FALSE)
getConditionalPower(stageResults, thetaH1 = -0.4,
nPlanned = c(64, 64), assumedStDev = 1.5, allocationRatioPlanned = 3)


[Package rpact version 3.3.2 Index]