exppower.noninf: Expected power of the non-inferiority test

View source: R/exppower_noninf.R

exppower.noninfR Documentation

Expected power of the non-inferiority test

Description

Calculates the so-called expected, i.e., unconditional, power for a variety of study designs used in bioequivalence studies.

Usage

exppower.noninf(alpha = 0.025, logscale = TRUE, theta0, margin, CV, n,
                design = "2x2", robust = FALSE, 
                prior.type = c("CV", "theta0", "both"), prior.parm = list(), 
                method = c("exact", "approx"))

Arguments

alpha

Significance level (one-sided). Defaults here to 0.025.

logscale

Should the data be used on log-transformed or on original scale? TRUE (default) or FALSE.

theta0

Assumed ‘true’ (or ‘observed’ in case of prior.type != "CV") ratio or difference.
In case of logscale=TRUE it must be given as ratio T/R.
If logscale=FALSE, the difference in means. In this case, the difference may be expressed in two ways: relative to the same (underlying) reference mean, i.e. as (T-R)/R = T/R - 1; or as difference in means T-R. Note that in the former case the units of margin and CV need also be given relative to the reference mean (specified as ratio).
Defaults to 0.95 if logscale=TRUE or to -0.05 if logscale=FALSE

margin

Non-inferiority margin.
In case of logscale=TRUE it is given as ratio.
If logscale=FALSE, the limit may be expressed in two ways: difference of means relative to the same (underlying) reference mean or in units of the difference of means. Note that in the former case the units of CV and theta0 need also be given relative to the reference mean (specified as ratio).
Defaults to 0.8 if logscale=TRUE or to -0.2 if logscale=FALSE.

CV

In case of logscale=TRUE the (geometric) coefficient of variation given as ratio.
If logscale=FALSE the argument refers to (residual) standard deviation of the response. In this case, standard deviation may be expressed two ways: relative to a reference mean (specified as ratio sigma/muR), i.e. again as a coefficient of variation; or untransformed, i.e. as standard deviation of the response. Note that in the former case the units of theta0, theta1 and theta2 need also be given relative to the reference mean (specified as ratio).

In case of cross-over studies this is the within-subject CV, in case of a parallel-group design the CV of the total variability.

n

Number of subjects under study.
Is total number if given as scalar, else number of subjects in the (sequence) groups. In the latter case the length of n has to be equal to the number of (sequence) groups.

design

Character string describing the study design. See known.designs() for designs covered in this package.

robust

Defaults to FALSE. Set to TRUE will use the degrees of freedom according to the ‘robust’ evaluation (aka Senn’s basic estimator). These degrees of freedom are calculated as n-seq.
See known.designs()$df2 for designs covered in this package.

prior.type

Specifies which parameter uncertainty should be accounted for. In case of prior.type = "CV" (the default), only the uncertainty with respect to the CV will be considered (i.e. the given treatment effect is assumed to be fix). In case of prior.type = "theta0" only uncertainty with respect to the treatment ratio/difference will be accounted for (i.e. the given CV is assumed to be fix). In case of prior.type = "both" the power value will be unconditional with respect to both the CV and theta0.

prior.parm

A list of parameters expressing the prior information about the variability and/or treatment effect. Possible components are df, SEM, m and design.
For prior.type = "CV" the degrees of freedom from the prior trial are required. This information can be provided by specifying the single component df or the combination consisting of m and design.
For prior.type = "theta0" the standard error of the treatment difference from the prior trial is required. This information can be provided by specifying the single component SEM or the combination consisting of m and design.
For prior.type = "both" the degrees of freedom and the standard error of the treatment difference are required. This information can be provided by specifying the combination consisting of df and SEM or via the combination m and design.
See 'Details' for a technical description on each component.

method

Defaults to method="exact". In that case the expected power will be calculated as expected value of the power with respect to the (prior) distribution of the respective parameter(s).
Set to method="approx" the expected power according to the approximate formulas given in the book from Julious or in the Julious/Owen paper will be calculated (using non-central t); this only affects prior.type = "CV".

Details

This function calculates the so-called expected power taking into account that usually the parameters (CV and/or theta0) are not known but estimated from a prior study with some uncertainty. The expected power is an unconditional power and can therefore be seen as probability for success. See references for further details.

The prior.parm argument is a list that can supply any of the following components:

df

Error degrees of freedom from the prior trial (>4, maybe non-integer). df = Inf is allowed and for method = "exact" the result will then coincide with power.noninf(...).
Note: This corresponds to the df of both the CV and the difference of means.

SEM

Standard error of the difference of means from the prior trial; must always be on additive scale (i.e., usually log-scale).

m

Number of subjects from prior trial. Specification is analogous to the main argument n.

design

Study design of prior trial. Specification is analogous to the main argument design.

For prior.parm, the combination consisting of df and SEM requires a somewhat advanced knowledge of the prior trial (provided in the raw output from for example the software SAS, or may be obtained via emmeans of package emmeans. However, it has the advantage that if there were missing data the exact degrees of freedom and standard error of the difference can be used, the former possibly being non-integer valued (e.g. if the Kenward-Roger method was used).

Details on argument prior.type:

CV

The expectation is calculated with respect to the Inverse-gamma distribution.

theta0

The expectation is calculated with respect to the conditional distribution theta0 | \sigma^2 = s^2 of the posteriori distribution of (theta0, \sigma^2) from the prior trial.

both

The expectation is calculated with respect to the posteriori distribution of (theta0, \sigma^2) from the prior trial. Numerical calculation of the two-dimensional integral is performed via cubature::hcubature.

Notes on the underlying hypotheses
If the supplied margin is < 0 (logscale=FALSE) or < 1 (logscale=TRUE), then it is assumed higher response values are better. The hypotheses are
⁠ H0: theta0 <= margin vs. H1: theta0 > margin⁠
where theta0 = mean(test)-mean(reference) if logscale=FALSE
or
⁠ H0: log(theta0) <= log(margin) vs. H1: log(theta0) > log(margin)⁠
where theta0 = mean(test)/mean(reference) if logscale=TRUE.

If the supplied margin is > 0 (logscale=FALSE) or > 1 (logscale=TRUE), then it is assumed lower response values are better. The hypotheses are
⁠ H0: theta0 >= margin vs. H1: theta0 < margin⁠
where theta0 = mean(test)-mean(reference) if logscale=FALSE
or
⁠ H0: log(theta0) >= log(margin) vs. H1: log(theta0) < log(margin)⁠
where theta0 = mean(test)/mean(reference) if logscale=TRUE.
This latter case may also be considered as ‘non-superiority’.

Value

Value of expected power according to the input.

Author(s)

B. Lang, D. Labes

References

Grieve AP. Confidence Intervals and Sample Sizes. Biometrics. 1991;47:1597–603. \Sexpr[results=rd]{tools:::Rd_expr_doi("10.2307/2532411")}

O’Hagan, Stevens, JW, Campell MJ. Assurance in Clinical Trial Design. Pharm Stat. 2005;4:187–201. \Sexpr[results=rd]{tools:::Rd_expr_doi("10.1002/pst.175")}

Julious SA, Owen RJ. Sample size calculations for clinical studies allowing for uncertainty in variance. Pharm Stat. 2006;5:29–37. \Sexpr[results=rd]{tools:::Rd_expr_doi("10.1002/pst.197")}

Julious SA. Sample sizes for Clinical Trials. Boca Raton: CRC Press / Chapman & Hall; 2010.

Bertsche A, Nehmitz G, Beyersmann J, Grieve AP. The predictive distribution of the residual variability in the linear-fixed effects model for clinical cross-over trials. Biom J. 2016;58(4):797–809. \Sexpr[results=rd]{tools:::Rd_expr_doi("10.1002/bimj.201500245")}

Box GEP, Tiao GC. Bayesian Inference in Statistical Analysis. Boston: Addison-Wesley; 1992.

Held L, Sabanes Bove D. Applied Statistical Inference. Likelihood and Bayes. Berlin, Heidelberg: Springer; 2014. \Sexpr[results=rd]{tools:::Rd_expr_doi("10.1007/978-3-642-37887-4")}

Senn S. Cross-over Trials in Clinical Research. Chichester: John Wiley & Sons; 2nd edition 2002.

Zierhut ML, Bycott P, Gibbs MA, Smith BP, Vicini P. Ignorance is not bliss: Statistical power is not probability of trial success. Clin Pharmacol Ther. 2015;99:356–9. \Sexpr[results=rd]{tools:::Rd_expr_doi("10.1002/cpt.257")}

See Also

expsampleN.noninf, power.noninf

Examples

# Expected power for non-inferiority test for a 2x2 crossover
# with 40 subjects. CV 30% known from a pilot 2x2 study with 
# 12 subjects 
# using all the defaults for other parameters (theta0 carved in stone)
# should give: [1] 0.6761068
exppower.noninf(CV = 0.3, n = 40, prior.parm = list(df = 12-2))
# or equivalently
exppower.noninf(CV = 0.3, n = 40, prior.parm = list(m = 12, design = "2x2"))

# May be also calculated via exppower.TOST() after setting upper acceptance limit 
# to Inf and alpha=0.025
exppower.TOST(CV = 0.3, n = 40, prior.parm = list(df = 10), theta2 = Inf, alpha=0.025)

# In contrast: Julious approximation
exppower.noninf(CV = 0.3, n = 40, prior.parm = list(df = 10), method = "approx")
# should give: [1] 0.6751358

# Compare this to the usual (conditional) power (CV known, "carved in stone")
power.noninf(CV = 0.3, n = 40)
# should give: [1] 0.7228685
# same as if setting df = Inf in function exppower.noninf()
exppower.noninf(CV = 0.3, n = 40, prior.parm = list(df = Inf))

# Expected power for a 2x2 crossover with 40 subjects
# CV 30% and theta0 = 0.95 known from a pilot 2x2 study with 12 subjects
# using uncertainty with respect to both CV and theta0
exppower.noninf(CV = 0.3, theta0 = 0.95, n = 40, 
                prior.parm = list(m = 12, design = "2x2"), prior.type = "both")
# should give a decrease of expected power to 0.5982852

PowerTOST documentation built on May 29, 2024, 4:40 a.m.