Theory
Theory
Theory
<
>
=
0 0
0 1
i
i
i
Z if
Z if
And obtain the n products R
1 1
,. R
n n
. The product is known as the positive signed
rank of Z
i
. The Wilcoxon Signed rank statistic T
+
is then the sum of the positive signed
ranks, namely,
=
+
=
n
i
i i
R T
1
Rejection Criteria:
Reject H
0
if T
+
2 / o
t > OR
2 /
2
) 1 (
o
t
n n
T
+
s
+
Otherwise dont reject
SIGN TEST
This test is used to analyze the influence of a treatment in a group of population.
The hypothesis for the test is given below:
Null hypothesis:
H
0
: u = 0
That is, there is zero shift in the location due to the treatment.
Alternative Hypothesis:
H
1
: = u 0
That is, there is shift in the location due to the treatment.
Procedure:
To compute the Wilcoxon signed rank statistic B define indicator variables
i
where
<
>
=
0 0
0 1
i
i
i
Z if
Z if
The Sign test statistic is given by
=
=
n
i
i
B
1
Rejection Criteria:
Reject H
0
if B
2 / 1 , 2 / o
b > OR ,
2 / 1 , 2 / o
t n B s
+
Otherwise dont reject
WILCOXON RANK SUM TEST:
This is used to test whether the distribution function of two different population
are same. The hypothesis corresponding to the test is given below:
Null Hypothesis:
H
0
: F (t) = G (t)
That is, X variable and the Y variable have the same probability distribution, but the
common distribution is not specified.
Alternative Hypothesis:
H
1
: F (t) = G (t)
That is, X variable and the Y variable doesnt have the same probability distribution.
By defining
) ( ) ( X E Y E = A , we have
H
0
: A = 0, means that the population means are equal or equivalently that he treatment
has no effect and
H
1
: A = 0
The population means arent equal, indicating that the treatment has effect.
Procedure:
To compute the Wilcoxon two sample rank sum statistic W, order the combined
sample of N = m + n, X values and Y values from least to greatest. Let S
1
denote the rank
of Y
1
in this joint ordering and so on. W is the sum of the ranks assigned to the Y values.
That is,
=
=
n
i
i
S W
1
Rejection Criteria:
Reject H
0
if W
2 / o
w > OR , ) 1 (
2 / o
w n m n W + + s Otherwise dont reject
KENDALL TEST FOR INDEPENDENCE
This test is used to test the independence between a pair of population. The
hypothesis for the test is as follows:
Null hypothesis:
H
o
: ) ( * ) ( ) , (
,
y F x F y x F
Y X Y X
= ) , (
,
y x F
Y X
is the joint distribution for the common
bivariate population of the (X, Y) pairs.
That is, the variable X and Y are independent.
Alternative hypothesis:
H
1
: ) ( * ) ( ) , (
,
y F x F y x F
Y X Y X
=
That is, the variable X and Y are not independent.
Procedure:
To compute the Kendall sample correlation statistic K, we first calculate the
values of the n(n-1)/2 paired sign statistics )) , ( ), , ((
j j i i
Y X Y X Q for n j i s < s 1 where
<
>
=
0 ) ( ) ( 1
0 ) ( ) ( 1
)) , ( ), , ((
a c b d if
a c b d if
d c b a Q
That is, each pair of subscripts (i, j) with i < j score 1 if (Y
j
Y
i
) (X
j
X
i
) is
positive and score if (Y
j
Y
i
) (X
j
X
i
) is negative. The Kendall Statistic is then given by
= + =
=
1
1 1
)) , ( ), , ((
n
i
n
i j
j j i i
Y X Y X Q K
Corresponding to adding up the 1s and -1s paired sign statistic
Rejection Criteria:
Reject H
0
if K
2 / o
k >
SPEARMAN TEST FOR INDEPENDENCE
This test is used to test the independence between a pair of population. The
hypothesis for the test is as follows:
Null hypothesis:
H
o
: ) ( * ) ( ) , (
,
y F x F y x F
Y X Y X
= ) , (
,
y x F
Y X
is the joint distribution for the common
bivariate population of the (X, Y) pairs.
That is, the variable X and Y are independent.
Alternative hypothesis:
H
1
: ) ( * ) ( ) , (
,
y F x F y x F
Y X Y X
=
That is, the variable X and Y are not independent.
Procedure:
To compute the Spearman rank correlation coefficient r
s
, we first order the n X
observation from least to greatest and let R
i
be the rank of X
i
, i=1,..n. in this ordering.
Similarly we separately order the n Y observation from least to greatest and let S
i
denote
the rank of Y
i
, i=1,2..n in this ordering. Then the Spearman rank correlation coefficient is
given by
) 1 (
2
) 1 (
2
) 1 (
12
2
1
)
`
=
=
n n
n n
S
n n
R
r
n
i
i i
s
= 1 -
) 1 (
6
2
1
2
=
n n
D
n
i
i
where D
i
= S
i
R
i
, i= 1,2 n
Rejection Criteria:
Reject H
0
if
s
r
o , s
r > ; otherwise dont reject
To compute the Kendall sample correlation statistic K, we first calculate the values of the
n(n-1)/2 paired sign statistics )) , ( ), , ((
j j i i
Y X Y X Q for n j i s < s 1 where
<
>
=
0 ) ( ) ( 1
0 ) ( ) ( 1
)) , ( ), , ((
a c b d if
a c b d if
d c b a Q
That is, each pair of subscripts (i, j) with i < j score 1 if (Y
j
Y
i
) (X
j
X
i
) is
positive and score if (Y
j
Y
i
) (X
j
X
i
) is negative. The Kendall Statistic is then given by
= + =
=
1
1 1
)) , ( ), , ((
n
i
n
i j
j j i i
Y X Y X Q K
Corresponding to adding up the 1s and -1s paired sign statistic
Rejection Criteria:
Reject H
0
if K
2 / o
k >