sgnrk: Signed rank test for equivalence of an arbitrary continuous distribution of the intraindividual
differences in terms of the probability of a positive sign of
a Walsh average: test statistic and critical upper bound
Description
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 \(D_i\). For details see Wellek S (2010) Testing statistical
hypotheses of equivalence and noninferiority. Second edition,\(\S\) 5.4.
Usage
sgnrk(alpha,n,qpl1,qpl2,d)
Arguments
alpha
significance level
n
sample size
qpl1
lower equivalence limit \(q_+^{\prime}\) to the target functional \(q_+\)
qpl2
upper equivalence limit \(q_+^{\prime\prime}\) to the target functional \(q_+\)
d
row vector with the intraindividual differences for all \(n\) pairs as components
Value
alpha
significance level
n
sample size
qpl1
lower equivalence limit \(q_+^{\prime}\) to the target functional \(q_+\)
qpl2
upper equivalence limit \(q_+^{\prime\prime}\) to the target functional \(q_+\)
U_pl
observed value of the \(U\)-statistics estimator of \(q_+\)
SIGMAH
square root of the estimated asymtotic variance of \(U_+\)
CRIT
upper critical bound to \(\big|U_+-\big(q_+^{\prime}+q_+^{\prime\prime}\big)/2\big|/\hat{\sigma}\)
REJ
indicator of a positive [=1] vs negative [=0] rejection decision to be taken with
the data under analysis
Details
\(q_+\) 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 \(\pi_+ = P[X>Y]\).
References
Wellek S: Testing statistical hypotheses of equivalence and noninferiority. Second edition.
Boca Raton: Chapman & Hall/CRC Press, 2010, \(\S\) 5.4.
# NOT RUN {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)
# }