Title: | Testing for Equivalence and Noninferiority |
---|---|
Description: | Making available in R the complete set of programs accompanying S. Wellek's (2010) monograph ''Testing Statistical Hypotheses of Equivalence and Noninferiority. Second Edition'' (Chapman&Hall/CRC). |
Authors: | Stefan Wellek, Peter Ziegler |
Maintainer: | Stefan Wellek <[email protected]> |
License: | CC0 |
Version: | 1.0.2 |
Built: | 2024-12-15 07:30:48 UTC |
Source: | CRAN |
The package makes available in R the complete set of programs accompanying S. Wellek's (2010) monograph "Testing Statistical Hypotheses of Equivalence and Noninferiority. Second Edition" (Chapman&Hall/CRC).
In order to keep execution time of all examples below the limit set by the CRAN administration, in a number of cases the function calls shown in the documentation contain specifications which are insufficient for real applications. This holds in particular true for the width sw of search grids, which should be chosen to be .001 or smaller. Similarly, the maximum number of interval halving steps to be carried out in finding maximally admissible significance levels should be set to values >= 10.
Stefan Wellek <[email protected]>
Peter Ziegler <[email protected]>
Maintainer: Stefan Wellek <[email protected]>
Wellek S: Testing statistical hypotheses of equivalence and noninferiority. Second edition. Boca Raton: Chapman & Hall/CRC Press, 2015.
bi2ste1(397,397,0.0,0.025,0.511,0.384) bi2ste2(0.0,0.025,0.95,0.8,0.80,1.0)
bi2ste1(397,397,0.0,0.025,0.511,0.384) bi2ste2(0.0,0.025,0.95,0.8,0.80,1.0)
The function computes the critical constants defining the uniformly most powerful (randomized) test
for the problem or
versus
, with
denoting the parameter of
a binomial distribution from which a single sample of size
is available. In the output, one also finds the power
against the alternative that the true value of
falls on the
midpoint of the hypothetical equivalence interval
bi1st(alpha,n,P1,P2)
bi1st(alpha,n,P1,P2)
alpha |
significance level |
n |
sample size |
P1 |
lower limit of the hypothetical equivalence
range for the binomial parameter |
P2 |
upper limit of the hypothetical equivalence
range for |
alpha |
significance level |
n |
sample size |
P1 |
lower limit of the hypothetical equivalence
range for the binomial parameter |
P2 |
upper limit of the hypothetical equivalence
range for |
C1 |
left-hand limit of the critical interval for
the observed number |
C2 |
right-hand limit of the critical interval for
|
GAM1 |
probability of rejecting the null hypothesis
when it turns out that |
GAM2 |
probability of rejecting the null hypothesis
for |
POWNONRD |
Power of the nonrandomized version of the test against the alternative |
POW |
Power of the randomized UMP test against the
alternative |
Stefan Wellek <[email protected]>
Peter Ziegler <[email protected]>
Wellek S: Testing statistical hypotheses of equivalence and noninferiority.
Second edition. Boca Raton: Chapman & Hall/CRC Press, 2010, 4.3.
bi1st(.05,273,.65,.75)
bi1st(.05,273,.65,.75)
The function computes exact values of the power of the randomized UMPU test for equivalence in the strict (i.e. two-sided) sense of two binomial distributions and the conservative nonrandomized version of that test. It is assumed that the samples being available from both distributions are independent.
bi2aeq1(m,n,rho1,rho2,alpha,p1,p2)
bi2aeq1(m,n,rho1,rho2,alpha,p1,p2)
m |
size of Sample 1 |
n |
size of Sample 2 |
rho1 |
lower limit of the hypothetical equivalence range for the odds ratio |
rho2 |
upper limit of the hypothetical equivalence range for the odds ratio |
alpha |
significance level |
p1 |
true success rate in Population 1 |
p2 |
true success rate in Population 2 |
m |
size of Sample 1 |
n |
size of Sample 2 |
rho1 |
lower limit of the hypothetical equivalence range for the odds ratio |
rho2 |
upper limit of the hypothetical equivalence range for the odds ratio |
alpha |
significance level |
p1 |
true success rate in Population 1 |
p2 |
true success rate in Population 2 |
POWNR |
Power of the nonrandomized version of the test |
POW |
Power of the randomized UMPU test |
Stefan Wellek <[email protected]>
Peter Ziegler <[email protected]>
Wellek S: Testing statistical hypotheses of equivalence and noninferiority.
Second edition. Boca Raton: Chapman & Hall/CRC Press, 2010, 6.6.4.
bi2aeq1(302,302,0.6667,1.5,0.05,0.5,0.5)
bi2aeq1(302,302,0.6667,1.5,0.05,0.5,0.5)
The function computes minimum sample sizes required in the randomized UMPU test for
equivalence of two binomial distributions with respect to the odds ratio. Computation is done under
the side condition that the ratio has some predefined value
.
bi2aeq2(rho1,rho2,alpha,p1,p2,beta,qlambd)
bi2aeq2(rho1,rho2,alpha,p1,p2,beta,qlambd)
rho1 |
lower limit of the hypothetical equivalence range for the odds ratio |
rho2 |
upper limit of the hypothetical equivalence range for the odds ratio |
alpha |
significance level |
p1 |
true success rate in Population 1 |
p2 |
true success rate in Population 2 |
beta |
target value of power |
qlambd |
sample size ratio |
rho1 |
lower limit of the hypothetical equivalence range for the odds ratio |
rho2 |
upper limit of the hypothetical equivalence range for the odds ratio |
alpha |
significance level |
p1 |
true success rate in Population 1 |
p2 |
true success rate in Population 2 |
beta |
target value of power |
qlambd |
sample size ratio |
M |
minimum size of Sample 1 |
N |
minimum size of Sample 2 |
POW |
Power of the randomized UMPU test attained with the computed values of m,n |
Stefan Wellek <[email protected]>
Peter Ziegler <[email protected]>
Wellek S: Testing statistical hypotheses of equivalence and noninferiority. Second edition.
Boca Raton: Chapman & Hall/CRC Press, 2010, 6.6.4.
bi2aeq2(0.5,2.0,0.05,0.5,0.5,0.60,1.0)
bi2aeq2(0.5,2.0,0.05,0.5,0.5,0.60,1.0)
The objective is to raise the nominal significance level as far as possible without exceeding the target significance level in the nonrandomized version of the test. The approach goes back to R.D. Boschloo (1970) who used the same technique for reducing the conservatism of the traditional nonrandomized Fisher test for superiority.
bi2aeq3(m,n,rho1,rho2,alpha,sw,tolrd,tol,maxh)
bi2aeq3(m,n,rho1,rho2,alpha,sw,tolrd,tol,maxh)
m |
size of Sample 1 |
n |
size of Sample 2 |
rho1 |
lower limit of the hypothetical equivalence range for the odds ratio |
rho2 |
upper limit of the hypothetical equivalence range for the odds ratio |
alpha |
significance level |
sw |
width of the search grid for determining the maximum of the rejection probability on the common boundary of the hypotheses |
tolrd |
horizontal distance from 0 and 1, respectively of the left- and right-most boundary point to be included in the search grid |
tol |
upper bound to the absolute difference between size and target level below which the search for a corrected nominal level terminates |
maxh |
maximum number of interval halving steps to be carried out in finding the maximally raised nominal level |
It should be noted that, as the function of the nominal level, the size of the nonrandomized test is piecewise constant. Accordingly, there is a nondegenerate interval of "candidate" nominal levels serving the purpose. The limits of such an interval can be read from the output. In terms of execution time, bi2aeq3 is the most demanding program of the whole package.
m |
size of Sample 1 |
n |
size of Sample 2 |
rho1 |
lower limit of the hypothetical equivalence range for the odds ratio |
rho2 |
upper limit of the hypothetical equivalence range for the odds ratio |
alpha |
significance level |
sw |
width of the search grid for determining the maximum of the rejection probability on the common boundary of the hypotheses |
tolrd |
horizontal distance from 0 and 1, respectively of the left- and right-most boundary point to be included in the search grid |
tol |
upper bound to the absolute difference between size and target level below which the search for a corrected nominal level terminates |
maxh |
maximum number of interval halving steps to be carried out in finding the maximally raised nominal level |
ALPH_0 |
current trial value of the raised nominal level searched for |
NHST |
number of interval-halving steps performed up to now |
SIZE |
size of the critical region corresponding to |
Stefan Wellek <[email protected]>
Peter Ziegler <[email protected]>
Boschloo RD: Raised conditional level of significance for the 2 x 2- table when testing the equality of two probabilities. Statistica Neerlandica 24 (1970), 1-35.
Wellek S: Testing statistical hypotheses of equivalence and noninferiority. Second edition.
Boca Raton: Chapman & Hall/CRC Press, 2010, 6.6.5.
bi2aeq3(50,50,0.6667,1.5000,0.05,0.01,0.000001,0.0001,5)
bi2aeq3(50,50,0.6667,1.5000,0.05,0.01,0.000001,0.0001,5)
Implementation of the construction described on pp. 185-6 of Wellek S (2010) Testing statistical hypotheses of equivalence and noninferiority. Second edition.
bi2by_ni_del(N1,N2,EPS,SW,NSUB,ALPHA,MAXH)
bi2by_ni_del(N1,N2,EPS,SW,NSUB,ALPHA,MAXH)
N1 |
size of Sample 1 |
N2 |
size of sample 2 |
EPS |
noninferiority margin to the difference of success probabilities |
SW |
width of the search grid for determining the maximum of the rejection probability on the common boundary of the hypotheses |
NSUB |
number of subintervals for partitioning the range of integration |
ALPHA |
target significance level |
MAXH |
maximum number of interval halving steps to be carried out in finding the maximally admissible nominal level |
The program uses 96-point Gauss-Legendre quadrature on each of the NSUB intervals into which the range of integration is partitioned.
N1 |
size of Sample 1 |
N2 |
size of sample 2 |
EPS |
noninferiority margin to the difference of success probabilities |
NSUB |
number of subintervals for partitioning the range of integration |
SW |
width of the search grid for determining the maximum of the rejection probability on the common boundary of the hypotheses |
ALPHA0 |
result of the search for the largest admissible nominal level |
SIZE0 |
size of the critical region corresponding to |
SIZE_UNC |
size of the critical region of the test at uncorrected nominal level |
Stefan Wellek <[email protected]>
Peter Ziegler <[email protected]>
Wellek S: Statistical methods for the analysis of two-armed non-inferiority trials with binary outcomes. Biometrical Journal 47 (2005), 48–61.
Wellek S: Testing statistical hypotheses of equivalence and
noninferiority. Second edition. Boca Raton:
Chapman & Hall/CRC Press, 2010, 6.6.3.
bi2by_ni_del(20,20,.10,.01,10,.05,5)
bi2by_ni_del(20,20,.10,.01,10,.05,5)
Implementation of the construction described on pp. 179–181 of Wellek S (2010) Testing statistical hypotheses of equivalence and noninferiority. Second edition.
bi2by_ni_OR(N1,N2,EPS,SW,NSUB,ALPHA,MAXH)
bi2by_ni_OR(N1,N2,EPS,SW,NSUB,ALPHA,MAXH)
N1 |
size of sample 1 |
N2 |
size of sample 2 |
EPS |
noninferiority margin to the deviation of the odds ratio from unity |
SW |
width of the search grid for determining the maximum of the rejection probability on the common boundary of the hypotheses |
NSUB |
number of subintervals for partitioning the range of integration |
ALPHA |
target significance level |
MAXH |
maximum number of interval halving steps to be carried out in finding the maximally admissible nominal level |
The program uses 96-point Gauss-Legendre quadrature on each of the NSUB intervals into which the range of integration is partitioned.
N1 |
size of sample 1 |
N2 |
size of sample 2 |
EPS |
noninferiority margin to the deviation of the odds ratio from unity |
NSUB |
number of subintervals for partitioning the range of integration |
SW |
width of the search grid for determining the maximum of the rejection probability on the common boundary of the hypotheses |
ALPHA0 |
result of the search for the largest admissible nominal level |
SIZE0 |
size of the critical region corresponding to |
SIZE_UNC |
size of the critical region of the test at uncorrected nominal level |
Stefan Wellek <[email protected]>
Peter Ziegler <[email protected]>
Wellek S: Statistical methods for the analysis of two-arm non-inferiority trials with binary outcomes. Biometrical Journal 47 (2005), 48–61.
Wellek S: Testing statistical hypotheses of equivalence and
noninferiority. Second edition. Boca Raton:
Chapman & Hall/CRC Press, 2010, 6.6.2.
bi2by_ni_OR(10,10,1/3,.0005,10,.05,12)
bi2by_ni_OR(10,10,1/3,.0005,10,.05,12)
of their population counterparts
The program computes the largest nominal significance level
which can be substituted for the target level without making the exact
size of the asymptotic testing procedure larger than
.
bi2diffac(alpha,m,n,del1,del2,sw,tolrd,tol,maxh)
bi2diffac(alpha,m,n,del1,del2,sw,tolrd,tol,maxh)
alpha |
significance level |
m |
size of Sample 1 |
n |
size of Sample 2 |
del1 |
absolute value of the lower limit of the hypothetical equivalence range for |
del2 |
upper limit of the hypothetical equivalence range for |
sw |
width of the search grid for determining the maximum of the rejection probability on the common boundary of the hypotheses |
tolrd |
horizontal distance of the left- and right-most boundary point to be included in the search grid |
tol |
upper bound to the absolute difference between size and target level below which the search for a corrected nominal level terminates |
maxh |
maximum number of interval halving steps to be carried out in finding the maximally raised nominal level |
alpha |
significance level |
m |
size of Sample 1 |
n |
size of Sample 2 |
del1 |
absolute value of the lower limit of the hypothetical equivalence range for |
del2 |
upper limit of the hypothetical equivalence range for |
sw |
width of the search grid for determining the maximum of the rejection probability on the common boundary of the hypotheses |
tolrd |
horizontal distance of the left- and right-most boundary point to be included in the search grid |
tol |
upper bound to the absolute difference between size and target level below which the search for a corrected nominal level terminates |
maxh |
maximum number of interval halving steps to be carried out in finding the maximally raised nominal level |
NH |
number of interval-halving steps actually performed |
ALPH_0 |
value of the raised nominal level obtained after NH steps |
SIZE0 |
size of the critical region corresponding to |
ERROR |
error indicator answering the question of whether or not the sufficient condition for the correctness of the result output by the program, was satisfied |
Stefan Wellek <[email protected]>
Peter Ziegler <[email protected]>
Wellek S: Testing statistical hypotheses of equivalence and noninferiority. Second edition.
Boca Raton: Chapman & Hall/CRC Press, 2010, 6.6.6.
bi2diffac(0.05,20,20,0.40,0.40,0.1,1e-6,1e-4,3)
bi2diffac(0.05,20,20,0.40,0.40,0.1,1e-6,1e-4,3)
The program computes exact values of the rejection probability of the asymptotic
test for equivalence in the sense of , at any nominal
level
. [The largest
for which the test is valid in terms of the
significance level, can be computed by means of the program bi2diffac.]
bi2dipow(alpha0,m,n,del1,del2,p1,p2)
bi2dipow(alpha0,m,n,del1,del2,p1,p2)
alpha0 |
nominal significance level |
m |
size of Sample 1 |
n |
size of Sample 2 |
del1 |
absolute value of the lower limit of the hypothetical equivalence range for |
del2 |
upper limit of the hypothetical equivalence range for |
p1 |
true value of the success probability in Population 1 |
p2 |
true value of the success probability in Population 2 |
alpha0 |
nominal significance level |
m |
size of Sample 1 |
n |
size of Sample 2 |
del1 |
absolute value of the lower limit of the hypothetical equivalence range for |
del2 |
upper limit of the hypothetical equivalence range for |
p1 |
true value of the success probability in Population 1 |
p2 |
true value of the success probability in Population 2 |
POWEX0 |
exact rejection probability under |
ERROR |
error indicator answering the question of whether or not the sufficient condition for the correctness of the result output by the program, was satisfied |
Stefan Wellek <[email protected]>
Peter Ziegler <[email protected]>
Wellek S: Testing statistical hypotheses of equivalence and noninferiority. Second edition.
Boca Raton: Chapman & Hall/CRC Press, 2010, 6.6.6.
bi2dipow(0.0228,50,50,0.20,0.20,0.50,0.50)
bi2dipow(0.0228,50,50,0.20,0.20,0.50,0.50)
The function computes exact values of the power of the randomized UMPU test for relevant differences between two binomial distributions and the conservative nonrandomized version of that test. It is assumed that the samples being available from both distributions are independent.
bi2rlv1(m,n,rho1,rho2,alpha,p1,p2)
bi2rlv1(m,n,rho1,rho2,alpha,p1,p2)
m |
size of Sample 1 |
n |
size of Sample 2 |
rho1 |
lower limit of the hypothetical equivalence range for the odds ratio |
rho2 |
upper limit of the hypothetical equivalence range for the odds ratio |
alpha |
significance level |
p1 |
true success rate in Population 1 |
p2 |
true success rate in Population 2 |
m |
size of Sample 1 |
n |
size of Sample 2 |
rho1 |
lower limit of the hypothetical equivalence range for the odds ratio |
rho2 |
upper limit of the hypothetical equivalence range for the odds ratio |
alpha |
significance level |
p1 |
true success rate in Population 1 |
p2 |
true success rate in Population 2 |
POWNR |
power of the nonrandomized version of the test |
POW |
power of the randomized UMPU test |
Stefan Wellek <[email protected]>
Peter Ziegler <[email protected]>
Wellek S: Testing statistical hypotheses of equivalence and noninferiority. Second edition.
Boca Raton: Chapman & Hall/CRC Press, 2010, 11.3.3.
bi2rlv1(200,300,.6667,1.5,.05,.25,.10)
bi2rlv1(200,300,.6667,1.5,.05,.25,.10)
The function computes minimum sample sizes required in the randomized UMPU test for
relevant differences between two binomial distributions with respect to the odds ratio. Computation is done
under the side condition that the ratio has some predefined value
.
bi2rlv2(rho1,rho2,alpha,p1,p2,beta,qlambd)
bi2rlv2(rho1,rho2,alpha,p1,p2,beta,qlambd)
rho1 |
lower limit of the hypothetical equivalence range for the odds ratio |
rho2 |
upper limit of the hypothetical equivalence range for the odds ratio |
alpha |
significance level |
p1 |
true success rate in Population 1 |
p2 |
true success rate in Population 2 |
beta |
target value of power |
qlambd |
sample size ratio |
rho1 |
lower limit of the hypothetical equivalence range for the odds ratio |
rho2 |
upper limit of the hypothetical equivalence range for the odds ratio |
alpha |
significance level |
p1 |
true success rate in Population 1 |
p2 |
true success rate in Population 2 |
beta |
target value of power |
qlambd |
sample size ratio |
M |
minimum size of Sample 1 |
N |
minimum size of Sample 2 |
POW |
power of the randomized UMPU test attained with the computed values of m, n |
Stefan Wellek <[email protected]>
Peter Ziegler <[email protected]>
Wellek S: Testing statistical hypotheses of equivalence and noninferiority. Second edition.
Boca Raton: Chapman & Hall/CRC Press, 2010, 11.3.3.
bi2rlv2(.6667,1.5,.05,.70,.50,.50,2.0)
bi2rlv2(.6667,1.5,.05,.70,.50,.50,2.0)
The function computes the critical constants defining the uniformly most powerful unbiased test for
equivalence of two binomial distributions with parameters
and
in terms of the odds ratio.
Like the ordinary Fisher type test of the null hypothesis
, the test is conditional on the total number
of successes in the pooled sample.
bi2st(alpha,m,n,s,rho1,rho2)
bi2st(alpha,m,n,s,rho1,rho2)
alpha |
significance level |
m |
size of Sample 1 |
n |
size of Sample 2 |
s |
observed total count of successes |
rho1 |
lower limit of the hypothetical equivalence
range for the odds ratio
|
rho2 |
upper limit of the hypothetical equivalence
range for |
alpha |
significance level |
m |
size of Sample 1 |
n |
size of Sample 2 |
s |
observed total count of successes |
rho1 |
lower limit of the hypothetical equivalence
range for the odds ratio
|
rho2 |
upper limit of the hypothetical equivalence
range for |
C1 |
left-hand limit of the critical interval for
the number |
C2 |
right-hand limit of the critical interval for
|
GAM1 |
probability of rejecting the null hypothesis
when it turns out that |
GAM2 |
probability of rejecting the null hypothesis
for |
Stefan Wellek <[email protected]>
Peter Ziegler <[email protected]>
Wellek S: Testing statistical hypotheses of equivalence and noninferiority.
Second edition. Boca Raton: Chapman & Hall/CRC Press, 2010, 6.6.4.
bi2st(.05,225,119,171, 2/3, 3/2)
bi2st(.05,225,119,171, 2/3, 3/2)
The function computes exact values of the power of the randomized UMPU test for one-sided equivalence of two binomial distributions and its conservative nonrandomized version. It is assumed that the samples being available from both distributions are independent.
bi2ste1(m, n, eps, alpha, p1, p2)
bi2ste1(m, n, eps, alpha, p1, p2)
m |
size of Sample 1 |
n |
size of Sample 2 |
eps |
noninferiority margin to the odds ratio |
alpha |
significance level |
p1 |
success rate in Population 1 |
p2 |
success rate in Population 2 |
m |
size of Sample 1 |
n |
size of Sample 2 |
eps |
noninferiority margin to the odds ratio |
alpha |
significance level |
p1 |
success rate in Population 1 |
p2 |
success rate in Population 2 |
POWNR |
power of the nonrandomized version of the test |
POW |
power of the randomized UMPU test |
Stefan Wellek <[email protected]>
Peter Ziegler <[email protected]>
Wellek S: Testing statistical hypotheses of equivalence and noninferiority. Second edition. Boca Raton: Chapman & Hall/CRC Press, 2010, 6.6.1.
bi2ste1(106,107,0.5,0.05,0.9245,0.9065)
bi2ste1(106,107,0.5,0.05,0.9245,0.9065)
Sample sizes for the exact Fisher type test for noninferiority
bi2ste2(eps, alpha, p1, p2, bet, qlambd)
bi2ste2(eps, alpha, p1, p2, bet, qlambd)
eps |
noninferiority margin to the odds ratio |
alpha |
significance level |
p1 |
success rate in Population 1 |
p2 |
success rate in Population 2 |
bet |
target power value |
qlambd |
sample size ratio |
The program computes the smallest sample sizes ,
satisfying
required for ensuring that the power of the randomized UMPU test does not
fall below
.
eps |
noninferiority margin to the odds ratio |
alpha |
significance level |
p1 |
success rate in Population 1 |
p2 |
success rate in Population 2 |
bet |
target power value |
qlambd |
sample size ratio |
M |
minimum size of Sample 1 |
N |
minimum size of Sample 2 |
POW |
power of the randomized UMPU test attained with the computed values of m, n |
Stefan Wellek <[email protected]>
Peter Ziegler <[email protected]>
Wellek S: Testing statistical hypotheses of equivalence and noninferiority. Second edition. Boca Raton: Chapman & Hall/CRC Press, 2010, 6.6.1.
bi2ste2(0.5,0.05,0.9245,0.9065,0.80,1.00)
bi2ste2(0.5,0.05,0.9245,0.9065,0.80,1.00)
The objective is to raise the nominal significance level as far as possible without exceeding the target significance level in the nonrandomized version of the test. The approach goes back to R.D. Boschloo (1970) who used the same technique for reducing the conservatism of the traditional nonrandomized Fisher test for superiority.
bi2ste3(m, n, eps, alpha, sw, tolrd, tol, maxh)
bi2ste3(m, n, eps, alpha, sw, tolrd, tol, maxh)
m |
size of Sample 1 |
n |
size of Sample 2 |
eps |
noninferiority margin to the odds ratio |
alpha |
target significance level |
sw |
width of the search grid for determining the maximum of the rejection probability on the common boundary of the hypotheses |
tolrd |
horizontal distance from 0 and 1, respectively, of the left- and right-most boundary point to be included in the search grid |
tol |
upper bound to the absolute difference between size and target level below which the search for a corrected nominal level terminates |
maxh |
maximum number of interval-halving steps to be carried out in finding the maximally raised nominal level |
It should be noted that, as the function of the nominal level, the size of the nonrandomized test is piecewise constant. Accordingly, there is a nondegenerate interval of "candidate" nominal levels serving the purpose. The limits of such an interval can be read from the output.
m |
size of Sample 1 |
n |
size of Sample 2 |
eps |
noninferiority margin to the odds ratio |
alpha |
target significance level |
sw |
width of the search grid for determining the maximum of the rejection probability on the common boundary of the hypotheses |
tolrd |
horizontal distance from 0 and 1, respectively, of the left- and right-most boundary point to be included in the search grid |
tol |
upper bound to the absolute difference between size and target level below which the search for a corrected nominal level terminates |
maxh |
maximum number of interval-halving steps to be carried out in finding the maximally raised nominal level |
ALPH_0 |
current trial value of the raised nominal level searched for |
NHST |
number of interval-halving steps performed up to now |
SIZE |
size of the critical region corresponding to |
Stefan Wellek <[email protected]>
Peter Ziegler <[email protected]>
Boschloo RD: Raised conditional level of significance for the 2 x 2- table when testing the equality of two probabilities. Statistica Neerlandica 24 (1970), 1-35.
Wellek S: Testing statistical hypotheses of equivalence and noninferiority.
Second edition. Boca Raton: Chapman & Hall/CRC Press, 2010, 6.6.2.
bi2ste3(50, 50, 1/3, 0.05, 0.05, 1e-10, 1e-8, 10)
bi2ste3(50, 50, 1/3, 0.05, 0.05, 1e-10, 1e-8, 10)
Implementation of the construction described on pp. 183-5 of Wellek S (2010) Testing statistical hypotheses of equivalence and noninferiority. Second edition.
bi2wld_ni_del(N1,N2,EPS,SW,ALPHA,MAXH)
bi2wld_ni_del(N1,N2,EPS,SW,ALPHA,MAXH)
N1 |
size of Sample 1 |
N2 |
size of Sample 2 |
EPS |
noninferiority margin to the difference of success probabilities |
SW |
width of the search grid for determining the maximum of the rejection probability on the common boundary of the hypotheses |
ALPHA |
target significance level |
MAXH |
maximum number of interval-halving steps |
The program computes the largest nominal significance level
to be used for determining the critical lower bound to the Wald-type statistic for the
problem of testing versus
.
N1 |
size of Sample 1 |
N2 |
size of Sample 2 |
EPS |
noninferiority margin to the difference of success probabilities |
SW |
width of the search grid for determining the maximum of the rejection probability on the common boundary of the hypotheses |
ALPHA |
target significance level |
MAXH |
maximum number of interval-halving steps |
ALPHA0 |
corrected nominal level |
SIZE0 |
size of the critical region of the test at nominal level ALPHA0 |
SIZE_UNC |
size of the test at uncorrected nominal level ALPHA |
ERR_IND |
indicator taking value 1 when it occurs that the sufficient condition allowing one to restrict the search for the maximum of the rejection probability under the null hypothesis to its boundary, fails to be satisfied; otherwise the indicator retains its default value 0. |
Stefan Wellek <[email protected]>
Peter Ziegler <[email protected]>
Wellek S: Testing statistical hypotheses of equivalence and
noninferiority. Second edition. Boca Raton:
Chapman & Hall/CRC Press, 2010, 6.6.3.
bi2wld_ni_del(25,25,.10,.01,.05,10)
bi2wld_ni_del(25,25,.10,.01,.05,10)
Implementation of the interval estimation procedure described on pp. 305-6 of Wellek S (2010) Testing statistical hypotheses of equivalence and noninferiority. Second edition.
cf_reh_exact(X1,X2,X3,alpha,SW,TOL,ITMAX)
cf_reh_exact(X1,X2,X3,alpha,SW,TOL,ITMAX)
X1 |
count of homozygotes of the first kind [ |
X2 |
count of heterozygotes [ |
X3 |
count of homozygotes of the second kind [ |
alpha |
1 - confidence level |
SW |
width of the search grid for determining an interval covering the
parameter point at which the conditional distribution function takes
value |
TOL |
numerical tolerance to the deviation between the computed confidence limits and their exact values |
ITMAX |
maximum number of interval-halving steps |
The program exploits the structure of the family of all genotype distributions,
which is 2-parameter exponential with as one of these parameters.
X1 |
count of homozygotes of the first kind [ |
X2 |
count of heterozygotes [ |
X3 |
count of homozygotes of the second kind [ |
alpha |
1 - confidence level |
SW |
width of the search grid for determining an interval covering the
parameter point at which the conditional distribution function takes
value |
TOL |
numerical tolerance to the deviation between the computed confidence limits and their exact values |
ITMAX |
maximum number of interval-halving steps |
C_l_exact |
exact conditional lower |
C_r_exact |
exact conditional upper |
Stefan Wellek <[email protected]>
Peter Ziegler <[email protected]>
Wellek S, Goddard KAB, Ziegler A: A confidence-limit-based approach to the assessment of Hardy-Weinberg equilibrium. Biometrical Journal 52 (2010), 253-270.
Wellek S: Testing statistical hypotheses of equivalence and
noninferiority. Second edition. Boca Raton:
Chapman & Hall/CRC Press, 2010, 9.4.3.
cf_reh_exact(34,118,96,.05,.1,1E-4,25)
cf_reh_exact(34,118,96,.05,.1,1E-4,25)
Implementation of the interval estimation procedure described on pp. 306-7 of Wellek S (2010) Testing statistical hypotheses of equivalence and noninferiority. Second edition.
cf_reh_midp(X1,X2,X3,alpha,SW,TOL,ITMAX)
cf_reh_midp(X1,X2,X3,alpha,SW,TOL,ITMAX)
X1 |
count of homozygotes of the first kind [ |
X2 |
count of heterozygotes [ |
X3 |
count of homozygotes of the second kind [ |
alpha |
1 - confidence level |
SW |
width of the search grid for determining an interval covering the
parameter point at which the conditional distribution function takes
value |
TOL |
numerical tolerance to the deviation between the computed confidence limits and their exact values |
ITMAX |
maximum number of interval-halving steps |
The mid-p algorithm serves as a device for reducing the conservatism inherent in exact confidence estimation procedures for parameters of discrete distributions.
X1 |
count of homozygotes of the first kind [ |
X2 |
count of heterozygotes [ |
X3 |
count of homozygotes of the second kind [ |
alpha |
1 - confidence level |
SW |
width of the search grid for determining an interval covering the
parameter point at which the conditional distribution function takes
value |
TOL |
numerical tolerance to the deviation between the computed confidence limits and their exact values |
ITMAX |
maximum number of interval-halving steps |
C_l_midp |
lower |
C_r_midp |
upper |
Stefan Wellek <[email protected]>
Peter Ziegler <[email protected]>
Agresti A: Categorical data Analysis (2nd edn). Hoboken, NJ: Wiley, Inc., 2002, Section 1.4.5.
Wellek S, Goddard KAB, Ziegler A: A confidence-limit-based approach to the assessment of Hardy-Weinberg equilibrium. Biometrical Journal 52 (2010), 253-270.
Wellek S: Testing statistical hypotheses of equivalence and
noninferiority. Second edition. Boca Raton:
Chapman & Hall/CRC Press, 2010, 9.4.3.
cf_reh_midp(137,34,8,.05,.1,1E-4,25)
cf_reh_midp(137,34,8,.05,.1,1E-4,25)
The function computes the critical constants defining the uniformly most powerful test for the problem
or
versus
,
with
denoting the scale parameter [
reciprocal hazard rate] of an exponential distribution.
exp1st(alpha,tol,itmax,n,eps)
exp1st(alpha,tol,itmax,n,eps)
alpha |
significance level |
tol |
tolerable deviation from |
itmax |
maximum number of iteration steps |
n |
sample size |
eps |
margin determining the hypothetical equivalence range symmetrically on the log-scale |
alpha |
significance level |
tol |
tolerable deviation from |
itmax |
maximum number of iteration steps |
n |
sample size |
eps |
margin determining the hypothetical equivalence range symmetrically on the log-scale |
IT |
number of iteration steps performed until reaching the stopping criterion corresponding to TOL |
C1 |
left-hand limit of the critical interval for
|
C2 |
right-hand limit of the critical interval for
|
ERR1 |
deviation of the rejection probability from |
POW0 |
power of the randomized UMP test against the
alternative |
Stefan Wellek <[email protected]>
Peter Ziegler <[email protected]>
Wellek S: Testing statistical hypotheses of equivalence and noninferiority.
Second edition. Boca Raton: Chapman & Hall/CRC Press, 2010, 4.2.
exp1st(0.05,1.0e-10,100,80,0.3)
exp1st(0.05,1.0e-10,100,80,0.3)
The function computes the critical constants defining the optimal test for the problem
or
versus
,
with
as a fixed nonempty interval around unity.
fstretch(alpha,tol,itmax,ny1,ny2,rho1,rho2)
fstretch(alpha,tol,itmax,ny1,ny2,rho1,rho2)
alpha |
significance level |
tol |
tolerable deviation from |
itmax |
maximum number of iteration steps |
ny1 |
number of degrees of freedom of the estimator of
|
ny2 |
number of degrees of freedom of the estimator of
|
rho1 |
lower equivalence limit to |
rho2 |
upper equivalence limit to |
alpha |
significance level |
tol |
tolerable deviation from |
itmax |
maximum number of iteration steps |
ny1 |
number of degrees of freedom of the estimator of
|
ny2 |
number of degrees of freedom of the estimator of
|
rho1 |
lower equivalence limit to |
rho2 |
upper equivalence limit to |
IT |
number of iteration steps performed until reaching the stopping criterion corresponding to TOL |
C1 |
left-hand limit of the critical interval for
|
C2 |
right-hand limit of the critical interval for
|
ERR |
deviation of the rejection probability from |
POW0 |
power of the UMPI test against the
alternative |
If the two independent samples under analysis are from exponential rather than Gaussian distributions, the critical constants computed by
means of fstretch with ,
, can be used
for testing for equivalence with respect to the ratio of hazard rates. The only difference is that the ratio of sample means rather than variances has
to be used as the test statistic then.
Stefan Wellek <[email protected]>
Peter Ziegler <[email protected]>
Wellek S: Testing statistical hypotheses of equivalence and noninferiority.
Second edition. Boca Raton: Chapman & Hall/CRC Press, 2010, 6.5.
fstretch(0.05, 1.0e-10, 50,40,45,0.5625,1.7689)
fstretch(0.05, 1.0e-10, 50,40,45,0.5625,1.7689)
The function computes the critical constants defining the uniformly most
powerful unbiased test for equivalence of the population distribution of the three genotypes
distinguishable in terms of a single nucleotide polymorphism (SNP), to a distribution
being in Hardy-Weinberg equilibrium (HWE).
The test is conditional on the total count of alleles of the kind of interest, and
the parameter
, in terms of which equivalence shall be established, is defined
by
, with
and
denoting
the population frequence of homozygotes of the 1st kind and heterozygotes, respectively.
gofhwex(alpha,n,s,del1,del2)
gofhwex(alpha,n,s,del1,del2)
alpha |
significance level |
n |
number of genotyped individuals |
s |
observed count of alleles of the kind of interest |
del1 |
absolute value of the lower equivalence limit to |
del2 |
upper equivalence limit to |
alpha |
significance level |
n |
number of genotyped individuals |
s |
observed count of alleles of the kind of interest |
del1 |
absolute value of the lower equivalence limit to |
del2 |
upper equivalence limit to |
C1 |
left-hand limit of the critical interval for the observed number |
C2 |
right-hand limit of the critical interval for the observed number |
GAM1 |
probability of rejecting the null hypothesis when it turns out that |
GAM2 |
probability of rejecting the null hypothesis for |
Stefan Wellek <[email protected]>
Peter Ziegler <[email protected]>
Wellek S: Tests for establishing compatibility of an observed genotype distribution with Hardy-Weinberg equilibrium in the case of a biallelic locus. Biometrics 60 (2004), 694-703.
Goddard KAB, Ziegler A, Wellek S: Adapting the logical basis of tests for Hardy-Weinberg equilibrium to the real needs of association studies in human and medical genetics. Genetic Epidemiology 33 (2009), 569-580.
Wellek S: Testing statistical hypotheses of equivalence and noninferiority.
Second edition. Boca Raton: Chapman & Hall/CRC Press, 2010, 9.4.2.
gofhwex(0.05,475,429,1-1/1.96,0.96)
gofhwex(0.05,475,429,1-1/1.96,0.96)
The function computes the critical constants defining the UMPU test for
one-sided equivalence of the population distribution of a SNP, to a distribution
being in Hardy-Weinberg equilibrium (HWE).
A substantial deficit of heterozygotes is defined to occur when the true value of the
parametric function [called relative excess
heterozygosity (REH)] falls below unity by more than some given margin
.
Like its two-sided counterpart [see the description of the R function gofhwex],
the test is conditional on the total count of alleles of the kind of interest.
gofhwex_1s(alpha,n,s,del0)
gofhwex_1s(alpha,n,s,del0)
alpha |
significance level |
n |
number of genotyped individuals |
s |
observed count of alleles of the kind of interest |
del0 |
noninferiority margin for |
alpha |
significance level |
n |
number of genotyped individuals |
s |
observed count of alleles of the kind of interest |
del0 |
noninferiority margin for |
C |
left-hand limit of the critical interval for the observed number |
GAM |
probability of rejecting the null hypothesis when it turns out that |
Stefan Wellek <[email protected]>
Peter Ziegler <[email protected]>
Wellek S: Testing statistical hypotheses of equivalence and noninferiority. Second edition. Boca Raton: Chapman & Hall/CRC Press, 2010, pp. 300-302.
gofhwex_1s(0.05,133,65,1-1/1.96)
gofhwex_1s(0.05,133,65,1-1/1.96)
The function computes all quantities required for carrying out the asymptotic test
for approximate independence of two categorial variables derived in 9.2 of
Wellek S (2010) Testing statistical hypotheses of equivalence and noninferiority. Second edition.
gofind_t(alpha,r,s,eps,xv)
gofind_t(alpha,r,s,eps,xv)
alpha |
significance level |
r |
number of rows of the contingency table under analysis |
s |
number of columns of the contingency table under analysis |
eps |
margin to the Euclidean distance between the vector |
xv |
row vector of length |
n |
size of the sample to which the input table relates |
alpha |
significance level |
r |
number of rows of the contingency table under analysis |
s |
number of columns of the contingency table under analysis |
eps |
margin to the Euclidean distance between the vector |
X(r , s)
|
observed cell counts |
DSQ_OBS |
observed value of the squared Euclidean distance |
VN |
square root of the estimated asymtotic variance of |
CRIT |
upper critical bound to |
REJ |
indicator of a positive [=1] vs negative [=0] rejection decision to be taken with the data under analysis |
Stefan Wellek <[email protected]>
Peter Ziegler <[email protected]>
Wellek S: Testing statistical hypotheses of equivalence and noninferiority. Second edition.
Boca Raton: Chapman & Hall/CRC Press, 2010, 9.2.
xv <- c(8, 13, 15, 6, 19, 21, 31, 7) gofind_t(0.05,2,4,0.15,xv)
xv <- c(8, 13, 15, 6, 19, 21, 31, 7) gofind_t(0.05,2,4,0.15,xv)
The function computes all quantities required for carrying out the asymptotic test for goodness
rather than lack of fit of an observed to a fully specified multinomial distribution
derived in 9.1 of Wellek S (2010) Testing statistical hypotheses of equivalence and noninferiority.
Second edition.
gofsimpt(alpha,n,k,eps,x,pio)
gofsimpt(alpha,n,k,eps,x,pio)
alpha |
significance level |
n |
sample size |
k |
number of categories |
eps |
margin to the Euclidean distance between the vectors |
x |
vector of length |
pio |
prespecified vector of cell probabilities |
alpha |
significance level |
n |
sample size |
k |
number of categories |
eps |
margin to the Euclidean distance between the vectors |
X(1 , K)
|
observed cell counts |
PI0(1 , K)
|
hypothecized cell probabilities |
DSQPIH_0 |
observed value of the squared Euclidean distance |
VN_N |
square root of the estimated asymtotic variance of |
CRIT |
upper critical bound to |
REJ |
indicator of a positive [=1] vs negative [=0] rejection decision to be taken with the data under analysis |
Stefan Wellek <[email protected]>
Peter Ziegler <[email protected]>
Wellek S: Testing statistical hypotheses of equivalence and noninferiority. Second edition.
Boca Raton: Chapman & Hall/CRC Press, 2010, 9.1.
x<- c(17,16,25,9,16,17) pio <- rep(1,6)/6 gofsimpt(0.05,100,6,0.15,x,pio)
x<- c(17,16,25,9,16,17) pio <- rep(1,6)/6 gofsimpt(0.05,100,6,0.15,x,pio)
Implementation of the asymptotically distribution-free test for
equivalence of two continuous distributions in terms of the Mann-Whitney-Wilcoxon functional.
For details see Wellek S (2010) Testing statistical hypotheses of equivalence and
noninferiority. Second edition, 6.2.
mawi(alpha,m,n,eps1_,eps2_,x,y)
mawi(alpha,m,n,eps1_,eps2_,x,y)
alpha |
significance level |
m |
size of Sample 1 |
n |
size of Sample 2 |
eps1_ |
absolute value of the left-hand limit of the hypothetical equivalence range for
|
eps2_ |
right-hand limit of the hypothetical equivalence range for |
x |
row vector with the |
y |
row vector with the |
Notation: stands for the Mann-Whitney functional defined by
,
with
cdf of Population 1 being independent of
cdf of Population 2.
alpha |
significance level |
m |
size of Sample 1 |
n |
size of Sample 2 |
eps1_ |
absolute value of the left-hand limit of the hypothetical equivalence range for
|
eps2_ |
right-hand limit of the hypothetical equivalence range for |
W+ |
observed value of the |
SIGMAH |
square root of the estimated asymtotic variance of |
CRIT |
upper critical bound to |
REJ |
indicator of a positive [=1] vs negative [=0] rejection decision to be taken with the data under analysis |
Stefan Wellek <[email protected]>
Peter Ziegler <[email protected]>
Wellek S: A new approach to equivalence assessment in standard comparative bioavailability trials by means of the Mann-Whitney statistic. Biometrical Journal 38 (1996), 695-710.
Wellek S: Testing statistical hypotheses of equivalence and noninferiority. Second edition.
Boca Raton: Chapman & Hall/CRC Press, 2010, 6.2.
x <- c(10.3,11.3,2.0,-6.1,6.2,6.8,3.7,-3.3,-3.6,-3.5,13.7,12.6) y <- c(3.3,17.7,6.7,11.1,-5.8,6.9,5.8,3.0,6.0,3.5,18.7,9.6) mawi(0.05,12,12,0.1382,0.2602,x,y)
x <- c(10.3,11.3,2.0,-6.1,6.2,6.8,3.7,-3.3,-3.6,-3.5,13.7,12.6) y <- c(3.3,17.7,6.7,11.1,-5.8,6.9,5.8,3.0,6.0,3.5,18.7,9.6) mawi(0.05,12,12,0.1382,0.2602,x,y)
The program computes the largest nominal significance level
which can be substituted for the target level without making the exact
size of the asymptotic testing procedure larger than
.
mcnasc_ni(alpha,n,del0,sw,tol,maxh)
mcnasc_ni(alpha,n,del0,sw,tol,maxh)
alpha |
significance level |
n |
sample size |
del0 |
absolute value of the noninferiority margin for |
sw |
width of the search grid for determining the maximum of the rejection probability on the common boundary of the hypotheses |
tol |
upper bound to the absolute difference between size and target level below which the search for a corrected nominal level terminates |
maxh |
maximum number of interval halving steps to be carried out in finding the maximally raised nominal level |
alpha |
significance level |
n |
sample size |
del0 |
absolute value of the noninferiority margin for |
sw |
width of the search grid for determining the maximum of the rejection probability on the common boundary of the hypotheses |
ALPH_0 |
value of the corrected nominal level obtained after nh steps |
SIZE_UNC |
exact size of the rejection region of the test at uncorrected nominal level |
SIZE0 |
exact size of the rejection region of the test at nominal level |
NH |
number of interval-halving steps actually performed |
Stefan Wellek <[email protected]>
Peter Ziegler <[email protected]>
Wellek S: Testing statistical hypotheses of equivalence and noninferiority. Second edition. Boca Raton:
Chapman & Hall/CRC Press, 2010, 5.2.3.
mcnasc_ni(0.05,50,0.05,0.05,0.0001,5)
mcnasc_ni(0.05,50,0.05,0.05,0.0001,5)
The program determines through iteration the largest nominal
level such that comparing the posterior probability
of the alternative hypothesis
to the lower
bound
generates a critical region whose size does not exceed
the target significance level
. In addition, exact values of the
power against specific parameter configurations with
are output.
mcnby_ni(N,DEL0,K1,K2,K3,NSUB,SW,ALPHA,MAXH)
mcnby_ni(N,DEL0,K1,K2,K3,NSUB,SW,ALPHA,MAXH)
N |
sample size |
DEL0 |
noninferiority margin to the difference of the parameters of the marginal binomial distributions under comparison |
K1 |
Parameter 1 of the Dirichlet prior for the family of trinomial distributions |
K2 |
Parameter 2 of the Dirichlet prior for the family of trinomial distributions |
K3 |
Parameter 3 of the Dirichlet prior for the family of trinomial distributions |
NSUB |
number of subintervals for partitioning the range of integration |
SW |
width of the search grid for determining the maximum of the rejection probability on the common boundary of the hypotheses |
ALPHA |
target significance level |
MAXH |
maximum number of interval halving steps to be carried out in finding the maximally raised nominal level |
The program uses 96-point Gauss-Legendre quadrature on each of the NSUB intervals into which the range of integration is partitioned.
N |
sample size |
DEL0 |
noninferiority margin to the difference of the parameters of the marginal binomial distributions under comparison |
K1 |
Parameter 1 of the Dirichlet prior for the family of trinomial distributions |
K2 |
Parameter 2 of the Dirichlet prior for the family of trinomial distributions |
K3 |
Parameter 3 of the Dirichlet prior for the family of trinomial distributions |
NSUB |
number of subintervals for partitioning the range of integration |
SW |
width of the search grid for determining the maximum of the rejection probability on the common boundary of the hypotheses |
ALPHA |
target significance level |
MAXH |
maximum number of interval halving steps to be carried out in finding the maximally raised nominal level |
ALPHA0 |
result of the search for the largest admissible nominal level |
SIZE0 |
size of the critical region corresponding to |
SIZE_UNC |
size of the critical region of test at uncorrected nominal level |
POW |
power against 7 different parameter configurations with |
Stefan Wellek <[email protected]>
Peter Ziegler <[email protected]>
Wellek S: Testing statistical hypotheses of equivalence and
noninferiority. Second edition. Boca Raton:
Chapman & Hall/CRC Press, 2010, 5.2.3.
mcnby_ni(25,.10,.5,.5,.5,10,.05,.05,5)
mcnby_ni(25,.10,.5,.5,.5,10,.05,.05,5)
Evaluation of the integral on the right-hand side of Equation (5.24) on p. 88 of Wellek S (2010) Testing statistical hypotheses of equivalence and noninferiority. Second edition.
mcnby_ni_pp(N,DEL0,N10,N01)
mcnby_ni_pp(N,DEL0,N10,N01)
N |
sample size |
DEL0 |
noninferiority margin to the difference of the parameters of the marginal binomial distributions under comparison |
N10 |
count of pairs with |
N01 |
count of pairs with |
The program uses 96-point Gauss-Legendre quadrature on each of 10 subintervals into which the range of integration is partitioned.
N |
sample size |
DEL0 |
noninferiority margin to the difference of the parameters of the marginal binomial distributions under comparison |
N10 |
count of pairs with |
N01 |
count of pairs with |
PPOST |
posterior probability of the alternative hypothesis |
The program uses Equation (5.24) of Wellek S (2010) corrected for a typo in the middle line which must read
.
Stefan Wellek <[email protected]>
Peter Ziegler <[email protected]>
Wellek S: Testing statistical hypotheses of equivalence and
noninferiority. Second edition. Boca Raton:
Chapman & Hall/CRC Press, 2010, 5.2.3.
mcnby_ni_pp(72,0.05,4,5)
mcnby_ni_pp(72,0.05,4,5)
The program computes the largest nominal significance level
which can be substituted for the target level without making the exact
size of the asymptotic testing procedure larger than
.
mcnemasc(alpha,n,del0,sw,tol,maxh)
mcnemasc(alpha,n,del0,sw,tol,maxh)
alpha |
significance level |
n |
sample size |
del0 |
upper limit set to |
sw |
width of the search grid for determining the maximum of the rejection probability on the common boundary of the hypotheses |
tol |
upper bound to the absolute difference between size and target level below which the search for a corrected nominal level terminates |
maxh |
maximum number of interval halving steps to be carried out in finding the maximally raised nominal level |
alpha |
significance level |
n |
sample size |
del0 |
upper limit set to |
sw |
width of the search grid for determining the maximum of the rejection probability on the common boundary of the hypotheses |
ALPH_0 |
value of the corrected nominal level obtained after nh steps |
NH |
number of interval-halving steps actually performed |
ERROR |
error indicator messaging "!!!!!" if the sufficient condition for the correctness of the result output by the program was found violated |
Stefan Wellek <[email protected]>
Peter Ziegler <[email protected]>
Wellek S: Testing statistical hypotheses of equivalence and noninferiority. Second edition.
Boca Raton: Chapman & Hall/CRC Press, 2010, 5.2.2.
mcnemasc(0.05,50,0.20,0.05,0.0005,5)
mcnemasc(0.05,50,0.20,0.05,0.0005,5)
The program computes exact values of the rejection probability of the asymptotic
test for equivalence in the sense of , at any nominal
level
. [The largest
for which the test is valid in terms of the
significance level, can be computed by means of the program mcnemasc.]
mcnempow(alpha,n,del0,p10,p01)
mcnempow(alpha,n,del0,p10,p01)
alpha |
nominal significance level |
n |
sample size |
del0 |
upper limit set to |
p10 |
true value of |
p01 |
true value of |
alpha |
nominal significance level |
n |
sample size |
del0 |
upper limit set to |
p10 |
true value of |
p01 |
true value of |
POW |
exact rejection probability of the asymptotic McNemar test for equivalence
at nominal level |
ERROR |
error indicator messaging "!!!!!" if the sufficient condition for the correctness of the result output by the program was found violated |
Stefan Wellek <[email protected]>
Peter Ziegler <[email protected]>
Wellek S: Testing statistical hypotheses of equivalence and noninferiority. Second edition. Boca Raton: Chapman & Hall/CRC Press, 2010, p.84.
mcnempow(0.024902,50,0.20,0.30,0.30)
mcnempow(0.024902,50,0.20,0.30,0.30)
Implementation of the asymptotically distribution-free test for equivalence of discrete distributions from which grouped data are obtained. Hypothesis formulation is in terms of the Mann-Whitney-Wilcoxon functional generalized to the case that ties between observations from different distributions may occur with positive probability. For details see Wellek S (2010) Testing statistical hypotheses of equivalence and noninferiority. Second edition, p.155.
mwtie_fr(k,alpha,m,n,eps1_,eps2_,x,y)
mwtie_fr(k,alpha,m,n,eps1_,eps2_,x,y)
k |
total number of grouped values which can be distinguished in the pooled sample |
alpha |
significance level |
m |
size of Sample 1 |
n |
size of Sample 2 |
eps1_ |
absolute value of the left-hand limit of the hypothetical equivalence range for
|
eps2_ |
right-hand limit of the hypothetical equivalence range for |
x |
row vector with the |
y |
row vector with the |
Notation: and
stands for the functional defined by
and
, respectively,
with
cdf of Population 1 being independent of
cdf of Population 2.
alpha |
significance level |
m |
size of Sample 1 |
n |
size of Sample 2 |
eps1_ |
absolute value of the left-hand limit of the hypothetical equivalence range for
|
eps2_ |
right-hand limit of the hypothetical equivalence range for |
WXY_TIE |
observed value of the |
SIGMAH |
square root of the estimated asymtotic variance of |
CRIT |
upper critical bound to |
REJ |
indicator of a positive [=1] vs negative [=0] rejection decision to be taken with the data under analysis |
Stefan Wellek <[email protected]>
Peter Ziegler <[email protected]>
Wellek S, Hampel B: A distribution-free two-sample equivalence test allowing for tied observations. Biometrical Journal 41 (1999), 171-186.
Wellek S: Testing statistical hypotheses of equivalence and noninferiority. Second edition.
Boca Raton: Chapman & Hall/CRC Press, 2010, 6.4.
x <- c(1,1,3,2,2,3,1,1,1,2,1,2,2,2,1,2,1,3,2,1,2,1,1,1,1,1,1,1,1,1,1,1,2,1,3,1,3,2,1,1, 2,1,2,1,1,2,2,1,2,1,1,1,1,1,2,2,1,2,2,1,3,1,2,1,1,2,2,1,2,2,1,1,1,3,2,1,1,1,2,1, 3,3,3,1,2,1,2,2,1,1,1,2,2,1,1,2,1,1,2,3,1,3,2,1,1,1,1,2,2,2,1,1,2,2,3,2,1,2,1,1, 2,2,1,2,2,2,1,1,2,3,2,1,3,2,1,1,1,2,2,2,2,1,2,2,1,1,1,1,2,1,1,1,2,1,2,2,1,2,2,2, 2,1,1,2,1,2,2,1,1,1,1,3,1,1,2,2,1,1,1,2,2,2,1,2,3,2,2,1,2,1,2,1,1,2,1,2,2,1,1,1, 2,2,2,2) y <- c(2,1,2,2,1,1,2,2,2,1,1,2,1,3,3,1,1,1,1,1,1,2,2,3,1,1,1,3,1,1,1,1,1,1,1,2,2,3,2,1, 2,2,2,1,2,1,1,2,2,1,2,1,1,1,1,2,1,2,1,1,3,1,1,1,2,2,2,1,1,1,1,2,1,2,1,1,2,2,2,2, 2,1,1,1,3,2,2,2,1,2,3,1,2,1,1,1,2,1,3,3,1,2,2,2,2,2,2,1,2,1,1,1,1,2,2,1,1,1,1,2, 1,3,1,1,2,1,2,1,2,2,2,1,2,2,2,1,1,1,2,1,2,1,2,1,1,1,2,1,2,2,1,1,1,1,2,2,3,1,3,1, 1,2,2,2,1,1,1,1,2,1,1,3,2,2,3,1,2,2,1,1,2,1,1,2,1,2,2,1,2,1,2,2,2,1,1,1,1,1,1,1, 1,1,1,2,1,3,2,2,1,1,1,2,2,1,1,2,1,2,1,2,2,2,1,2,3,1,1,2,1,2,2,1,1,1,1,2,2,2,1,1, 3,2,1,2,2,2,1,1,1,2,1,2,2,1,2,1,1,2) mwtie_fr(3,0.05,204,258,0.10,0.10,x,y)
x <- c(1,1,3,2,2,3,1,1,1,2,1,2,2,2,1,2,1,3,2,1,2,1,1,1,1,1,1,1,1,1,1,1,2,1,3,1,3,2,1,1, 2,1,2,1,1,2,2,1,2,1,1,1,1,1,2,2,1,2,2,1,3,1,2,1,1,2,2,1,2,2,1,1,1,3,2,1,1,1,2,1, 3,3,3,1,2,1,2,2,1,1,1,2,2,1,1,2,1,1,2,3,1,3,2,1,1,1,1,2,2,2,1,1,2,2,3,2,1,2,1,1, 2,2,1,2,2,2,1,1,2,3,2,1,3,2,1,1,1,2,2,2,2,1,2,2,1,1,1,1,2,1,1,1,2,1,2,2,1,2,2,2, 2,1,1,2,1,2,2,1,1,1,1,3,1,1,2,2,1,1,1,2,2,2,1,2,3,2,2,1,2,1,2,1,1,2,1,2,2,1,1,1, 2,2,2,2) y <- c(2,1,2,2,1,1,2,2,2,1,1,2,1,3,3,1,1,1,1,1,1,2,2,3,1,1,1,3,1,1,1,1,1,1,1,2,2,3,2,1, 2,2,2,1,2,1,1,2,2,1,2,1,1,1,1,2,1,2,1,1,3,1,1,1,2,2,2,1,1,1,1,2,1,2,1,1,2,2,2,2, 2,1,1,1,3,2,2,2,1,2,3,1,2,1,1,1,2,1,3,3,1,2,2,2,2,2,2,1,2,1,1,1,1,2,2,1,1,1,1,2, 1,3,1,1,2,1,2,1,2,2,2,1,2,2,2,1,1,1,2,1,2,1,2,1,1,1,2,1,2,2,1,1,1,1,2,2,3,1,3,1, 1,2,2,2,1,1,1,1,2,1,1,3,2,2,3,1,2,2,1,1,2,1,1,2,1,2,2,1,2,1,2,2,2,1,1,1,1,1,1,1, 1,1,1,2,1,3,2,2,1,1,1,2,2,1,1,2,1,2,1,2,2,2,1,2,3,1,1,2,1,2,2,1,1,1,1,2,2,2,1,1, 3,2,1,2,2,2,1,1,1,2,1,2,2,1,2,1,1,2) mwtie_fr(3,0.05,204,258,0.10,0.10,x,y)
Implementation of the asymptotically distribution-free test for
equivalence of discrete distributions in terms of the Mann-Whitney-Wilcoxon functional
generalized to the case that ties between observations from different distributions may
occur with positive probability. For details see Wellek S (2010) Testing statistical hypotheses of
equivalence and noninferiority. Second edition, 6.4.
mwtie_xy(alpha,m,n,eps1_,eps2_,x,y)
mwtie_xy(alpha,m,n,eps1_,eps2_,x,y)
alpha |
significance level |
m |
size of Sample 1 |
n |
size of Sample 2 |
eps1_ |
absolute value of the left-hand limit of the hypothetical equivalence range for
|
eps2_ |
right-hand limit of the hypothetical equivalence range for |
x |
row vector with the |
y |
row vector with the |
Notation: and
stands for the functional defined by
and
, respectively,
with
cdf of Population 1 being independent of
cdf of Population 2.
alpha |
significance level |
m |
size of Sample 1 |
n |
size of Sample 2 |
eps1_ |
absolute value of the left-hand limit of the hypothetical equivalence range for
|
eps2_ |
right-hand limit of the hypothetical equivalence range for |
WXY_TIE |
observed value of the |
SIGMAH |
square root of the estimated asymtotic variance of |
CRIT |
upper critical bound to |
REJ |
indicator of a positive [=1] vs negative [=0] rejection decision to be taken with the data under analysis |
Stefan Wellek <[email protected]>
Peter Ziegler <[email protected]>
Wellek S, Hampel B: A distribution-free two-sample equivalence test allowing for tied observations. Biometrical Journal 41 (1999), 171-186.
Wellek S: Testing statistical hypotheses of equivalence and noninferiority. Second edition.
Boca Raton: Chapman & Hall/CRC Press, 2010, 6.4.
x <- c(1,1,3,2,2,3,1,1,1,2) y <- c(2,1,2,2,1,1,2,2,2,1,1,2) mwtie_xy(0.05,10,12,0.10,0.10,x,y)
x <- c(1,1,3,2,2,3,1,1,1,2) y <- c(2,1,2,2,1,1,2,2,2,1,1,2) mwtie_xy(0.05,10,12,0.10,0.10,x,y)
Implementation of the algorithm presented in 10.3.3 of
Wellek S (2010) Testing statistical hypotheses of equivalence and
noninferiority. Second edition.
po_pbibe(n,eps,pio,zq,s,tol,sw,ihmax)
po_pbibe(n,eps,pio,zq,s,tol,sw,ihmax)
n |
sample size |
eps |
equivalence margin to an individual log-bioavailability ratio |
pio |
prespecified lower bound to the probability of obtaining an individual
log-bioavailability ratio falling in the equivalence range |
zq |
mean log-bioavailability ratio observed in the sample under analysis |
s |
square root of the sample variance of the log-bioavailability ratios |
tol |
maximum numerical error allowed for transforming the hypothesis of PBIBE into a region in the parameter space of the log-normal distribution assumed to underlie the given sample of individual bioavailability ratios |
sw |
step width used in the numerical procedure yielding results at a level of accuracy specified by the value chosen for tol |
ihmax |
maximum number of interval halving steps to be carried out in finding the region specified in the parameter space according to the criterion of PBIBE |
The program uses 96-point Gauss-Legendre quadrature.
n |
sample size |
eps |
equivalence margin to an individual log-bioavailability ratio |
pio |
prespecified lower bound to the probability of obtaining an individual
log-bioavailability ratio falling in the equivalence range |
zq |
mean log-bioavailability ratio observed in the sample under analysis |
s |
square root of the sample variance of the log-bioavailability ratios |
tol |
maximum numerical error allowed for transforming the hypothesis of PBIBE into a region in the parameter space of the log-normal distribution assumed to underlie the given sample of individual bioavailability ratios |
sw |
step width used in the numerical procedure yielding results at a level of accuracy specified by the value chosen for tol |
ihmax |
maximum number of interval halving steps to be carried out in finding the region specified in the parameter space according to the criterion of PBIBE |
PO_PBIBE |
posterior probability of the alternative hypothesis of PBIBE |
Stefan Wellek <[email protected]>
Peter Ziegler <[email protected]>
Wellek S: Bayesian construction of an improved parametric test for probability-based individual bioequivalence. Biometrical Journal 42 (2000), 1039-52.
Wellek S: Testing statistical hypotheses of equivalence and
noninferiority. Second edition. Boca Raton: Chapman & Hall/CRC Press, 2010, 10.3.3.
po_pbibe(20,0.25,0.75,0.17451,0.04169, 10e-10,0.01,100)
po_pbibe(20,0.25,0.75,0.17451,0.04169, 10e-10,0.01,100)
Evaluation of the integral appearing on the right-hand side of equation (3.6) on p. 38 of Wellek S (2010) Testing statistical hypotheses of equivalence and noninferiority. Second edition
postmys(n,dq,sd,eps1,eps2,tol)
postmys(n,dq,sd,eps1,eps2,tol)
n |
sample size |
dq |
mean within-pair difference observed in the sample under analysis |
sd |
square root of the sample variance of the within-pair differences |
eps1 |
absolute value of the left-hand limit of the hypothetical equivalence range
for |
eps2 |
right-hand limit of the hypothetical equivalence range for |
tol |
tolerance for the error induced through truncating the range of integration on the right |
The program uses 96-point Gauss-Legendre quadrature.
n |
sample size |
dq |
mean within-pair difference observed in the sample under analysis |
sd |
square root of the sample variance of the within-pair differences |
eps1 |
absolute value of the left-hand limit of the hypothetical equivalence range
for |
eps2 |
right-hand limit of the hypothetical equivalence range for |
tol |
tolerance for the error induced through truncating the range of integration on the right |
PPOST |
posterior probability of the set of all |
Stefan Wellek <[email protected]>
Peter Ziegler <[email protected]>
Wellek S: Testing statistical hypotheses of equivalence and
noninferiority. Second edition. Boca Raton: Chapman & Hall/CRC Press, 2010, 3.2.
postmys(23,0.16,3.99,0.5,0.5,1e-6)
postmys(23,0.16,3.99,0.5,0.5,1e-6)
Evaluation of the integral on the right-hand side of equation (10.11) of p. 317 of Wellek S (2010) Testing statistical hypotheses of equivalence and noninferiority. Second edition
pow_abe(m,n,alpha,del_0,del,sig)
pow_abe(m,n,alpha,del_0,del,sig)
m |
sample size in sequence group T(est)/R(eference) |
n |
sample size in sequence group R(eference)/T(est) |
alpha |
significance level |
del_0 |
equivalence margin to the absolute value of the log-ratio |
del |
assumed true value of |
sig |
theoretical standard deviation of the log within-subject bioavailability ratios in each sequence group |
The program uses 96-point Gauss-Legendre quadrature.
m |
sample size in sequence group T(est)/R(eference) |
n |
sample size in sequence group R(eference)/T(est) |
alpha |
significance level |
del_0 |
equivalence margin to the absolute value of the log-ratio |
del |
assumed true value of |
POW_ABE |
power of the interval inclusion test for average bioequivalence against the
specific alternative given by |
Stefan Wellek <[email protected]>
Peter Ziegler <[email protected]>
Wellek S: Testing statistical hypotheses of equivalence and
noninferiority. Second edition. Boca Raton: Chapman & Hall/CRC Press, 2010, 10.2.1.
pow_abe(12,13,0.05,log(1.25),log(1.25)/2,0.175624)
pow_abe(12,13,0.05,log(1.25),log(1.25)/2,0.175624)
The program computes for each possible value of the number of
zero observations the power conditional on
and averages
these conditional power values with respect to the distribution of
.
Equivalence is defined in terms of the logarithm of the ratio
, where
and
denotes the probability of obtaining a positive and negative
sign, respectively.
powsign(alpha,n,eps1,eps2,poa)
powsign(alpha,n,eps1,eps2,poa)
alpha |
significance level |
n |
sample size |
eps1 |
absolute value of the lower limit of the hypothetical equivalence range for
|
eps2 |
upper limit of the hypothetical equivalence range for |
poa |
probability of a tie under the alternative of interest |
alpha |
significance level |
n |
sample size |
eps1 |
absolute value of the lower limit of the hypothetical equivalence range for
|
eps2 |
upper limit of the hypothetical equivalence range for |
poa |
probability of a tie under the alternative of interest |
POWNONRD |
power of the nonrandomized version of the test against the alternative
|
POW |
power of the randomized UMPU test against the alternative
|
A special case of the test whose power is computed by this program, is the exact conditional equivalence test for the McNemar setting (cf. Wellek 2010, pp. 76-77).
Stefan Wellek <[email protected]>
Peter Ziegler <[email protected]>
Wellek S: Testing statistical hypotheses of equivalence and noninferiority. Second edition.
Boca Raton: Chapman & Hall/CRC Press, 2010, 5.1.
powsign(0.06580,50,0.847298,0.847298,0.26)
powsign(0.06580,50,0.847298,0.847298,0.26)
Implementation of the paired-data analogue of the Mann-Whitney-Wilcoxon test for
equivalence of continuous distributions. The continuity assumption relates to the
intraindividual differences . For details see Wellek S (2010) Testing statistical
hypotheses of equivalence and noninferiority. Second edition,
5.4.
sgnrk(alpha,n,qpl1,qpl2,d)
sgnrk(alpha,n,qpl1,qpl2,d)
alpha |
significance level |
n |
sample size |
qpl1 |
lower equivalence limit |
qpl2 |
upper equivalence limit |
d |
row vector with the intraindividual differences for all |
is the probability of getting a positive sign of the so-called Walsh-average
of a pair of within-subject differences and can be viewed as a natural paired-observations
analogue of the Mann-Whitney functional
.
alpha |
significance level |
n |
sample size |
qpl1 |
lower equivalence limit |
qpl2 |
upper equivalence limit |
U_pl |
observed value of the |
SIGMAH |
square root of the estimated asymtotic variance of |
CRIT |
upper critical bound to |
REJ |
indicator of a positive [=1] vs negative [=0] rejection decision to be taken with the data under analysis |
Stefan Wellek <[email protected]>
Peter Ziegler <[email protected]>
Wellek S: Testing statistical hypotheses of equivalence and noninferiority. Second edition.
Boca Raton: Chapman & Hall/CRC Press, 2010, 5.4.
d <- c(-0.5,0.333,0.667,1.333,1.5,-2.0,-1.0,-0.167,1.667,0.833,-2.167,-1.833, 4.5,-7.5,2.667,3.333,-4.167,5.667,2.333,-2.5) sgnrk(0.05,20,0.2398,0.7602,d)
d <- c(-0.5,0.333,0.667,1.333,1.5,-2.0,-1.0,-0.167,1.667,0.833,-2.167,-1.833, 4.5,-7.5,2.667,3.333,-4.167,5.667,2.333,-2.5) sgnrk(0.05,20,0.2398,0.7602,d)
Implementation of a generalized version of the signed-rank test for equivalence
allowing for arbitrary patterns of ties between the within-subject differences.
For details see Wellek S (2010) Testing statistical hypotheses of equivalence and
noninferiority. Second edition, 5.5.
srktie_d(n,alpha,eps1,eps2,d)
srktie_d(n,alpha,eps1,eps2,d)
n |
sample size |
alpha |
significance level |
eps1 |
absolute value of the left-hand limit of the hypothetical equivalence range for
|
eps2 |
right-hand limit of the hypothetical equivalence range for |
d |
row vector with the intraindividual differences for all |
Notation: and
stands for the functional defined by
and
, respectively,
with
and
as the intraindividual differences observed in two individuals
independently selected from the underlying bivariate population.
n |
sample size |
alpha |
significance level |
eps1 |
absolute value of the left-hand limit of the hypothetical equivalence range for
|
eps2 |
right-hand limit of the hypothetical equivalence range for |
U_pl |
observed value of the |
U_0 |
observed value of the |
UAS_PL |
observed value of |
TAUHAS |
square root of the estimated asymtotic variance of |
CRIT |
upper critical bound to |
REJ |
indicator of a positive [=1] vs negative [=0] rejection decision to be taken with the data under analysis |
The function srktie_d can be viewed as the paired-data analogue of mwtie_xy
Stefan Wellek <[email protected]>
Peter Ziegler <[email protected]>
Wellek S: Testing statistical hypotheses of equivalence and noninferiority. Second edition.
Boca Raton: Chapman & Hall/CRC Press, 2010, 5.5.
d <- c(0.8,0.2,0.0,-0.1,-0.3,0.3,-0.1,0.4,0.6,0.2,0.0,-0.2,-0.3,0.0,0.1,0.3,-0.3, 0.1,-0.2,-0.5,0.2,-0.1,0.2,-0.1) srktie_d(24,0.05,0.2602,0.2602,d)
d <- c(0.8,0.2,0.0,-0.1,-0.3,0.3,-0.1,0.4,0.6,0.2,0.0,-0.2,-0.3,0.0,0.1,0.3,-0.3, 0.1,-0.2,-0.5,0.2,-0.1,0.2,-0.1) srktie_d(24,0.05,0.2602,0.2602,d)
Analogue of the function srktie_d tailored for settings where the distribution of the within-subject differences is concentrated on a finite lattice. For details see Wellek S (2010) Testing statistical hypotheses of equivalence and noninferiority. Second edition, pp.112-3.
srktie_m(n,alpha,eps1,eps2,w,d)
srktie_m(n,alpha,eps1,eps2,w,d)
n |
sample size |
alpha |
significance level |
eps1 |
absolute value of the left-hand limit of the hypothetical equivalence range for
|
eps2 |
right-hand limit of the hypothetical equivalence range for |
w |
span of the lattice in which the intraindividual differences take their values |
d |
row vector with the intraindividual differences for all |
Notation: and
stands for the functional defined by
and
, respectively,
with
and
as the intraindividual differences observed in two individuals
independently selected from the underlying bivariate population.
n |
sample size |
alpha |
significance level |
eps1 |
absolute value of the left-hand limit of the hypothetical equivalence range for
|
eps2 |
right-hand limit of the hypothetical equivalence range for |
w |
span of the lattice in which the intraindividual differences take their values |
U_pl |
observed value of the |
U_0 |
observed value of the |
UAS_PL |
observed value of |
TAUHAS |
square root of the estimated asymtotic variance of |
CRIT |
upper critical bound to |
REJ |
indicator of a positive [=1] vs negative [=0] rejection decision to be taken with the data under analysis |
Stefan Wellek <[email protected]>
Peter Ziegler <[email protected]>
Wellek S: Testing statistical hypotheses of equivalence and noninferiority. Second edition. Boca Raton: Chapman & Hall/CRC Press, 2010, pp. 112-114.
d <- c(0.8,0.2,0.0,-0.1,-0.3,0.3,-0.1,0.4,0.6,0.2,0.0,-0.2,-0.3,0.0,0.1,0.3,-0.3, 0.1,-0.2,-0.5,0.2,-0.1,0.2,-0.1) srktie_m(24,0.05,0.2602,0.2602,0.1,d)
d <- c(0.8,0.2,0.0,-0.1,-0.3,0.3,-0.1,0.4,0.6,0.2,0.0,-0.2,-0.3,0.0,0.1,0.3,-0.3, 0.1,-0.2,-0.5,0.2,-0.1,0.2,-0.1) srktie_m(24,0.05,0.2602,0.2602,0.1,d)
The function computes the critical constants defining the uniformly most powerful
invariant test for the problem
or
versus
, with
as a
fixed nondegenerate interval on the real line.
In addition, tt1st outputs the power against the null alternative
.
tt1st(n,alpha,theta1,theta2,tol,itmax)
tt1st(n,alpha,theta1,theta2,tol,itmax)
n |
sample size |
alpha |
significance level |
theta1 |
lower equivalence limit to |
theta2 |
upper equivalence limit to |
tol |
tolerable deviation from |
itmax |
maximum number of iteration steps |
n |
sample size |
alpha |
significance level |
theta1 |
lower equivalence limit to |
theta2 |
upper equivalence limit to |
IT |
number of iteration steps performed until reaching the stopping criterion corresponding to TOL |
C1 |
left-hand limit of the critical interval for the one-sample |
C2 |
right-hand limit of the critical interval for the one-sample |
ERR1 |
deviation of the rejection probability from |
ERR2 |
deviation of the rejection probability from |
POW0 |
power of the UMPI test against the alternative |
If the output value of ERR2 is NA, the deviation of the rejection probability at the right-hand
boundary of the hypothetical equivalence interval from is smaller than the smallest
real number representable in R.
Stefan Wellek <[email protected]>
Peter Ziegler <[email protected]>
Wellek S: Testing statistical hypotheses of equivalence and noninferiority. Second edition.
Boca Raton: Chapman & Hall/CRC Press, 2010, 5.3.
tt1st(36,0.05, -0.4716,0.3853,1e-10,50)
tt1st(36,0.05, -0.4716,0.3853,1e-10,50)
The function computes the critical constants defining the uniformly most powerful
invariant test for the problem
or
versus
, with
and
denoting
the expected values of two normal distributions with common variance
from which independent
samples are taken.
In addition, tt2st outputs the power against the null alternative
.
tt2st(m,n,alpha,eps1,eps2,tol,itmax)
tt2st(m,n,alpha,eps1,eps2,tol,itmax)
m |
size of the sample from |
n |
size of the sample from |
alpha |
significance level |
eps1 |
absolute value of the lower equivalence limit to |
eps2 |
upper equivalence limit to |
tol |
tolerable deviation from |
itmax |
maximum number of iteration steps |
m |
size of the sample from |
n |
size of the sample from |
alpha |
significance level |
eps1 |
absolute value of the lower equivalence limit to |
eps2 |
upper equivalence limit to |
IT |
number of iteration steps performed until reaching the stopping criterion corresponding to TOL |
C1 |
left-hand limit of the critical interval for the two-sample |
C2 |
right-hand limit of the critical interval for the two-sample |
ERR1 |
deviation of the rejection probability from |
ERR2 |
deviation of the rejection probability from |
POW0 |
power of the UMPI test against the alternative |
If the output value of ERR2 is NA, the deviation of the rejection probability at the right-hand
boundary of the hypothetical equivalence interval from is smaller than the smallest
real number representable in R.
Stefan Wellek <[email protected]>
Peter Ziegler <[email protected]>
Wellek S: Testing statistical hypotheses of equivalence and noninferiority. Second edition.
Boca Raton: Chapman & Hall/CRC Press, 2010, 6.1.
tt2st(12,12,0.05,0.50,1.00,1e-10,50)
tt2st(12,12,0.05,0.50,1.00,1e-10,50)