Additional file 1 - Algorithm for computing

advertisement
k 1
Additional file 1 - Algorithm for computing
v
i 1
2
i
Consider the case of i ties. Let l0 = 0 and C00  1 . Then under H0,
vi2 

1l1 .... li  k
k
k
k
n*[ (nt  1) I (t l1 )I (t li ) ]{ [
t 1
m 1 n 1
k i  m k i  n
1
  cuv ]}
(2k  i)! u m vn
cuv  [k  t1  t 2  t3  t 4  I (m  l1 )  I (m  li )]! [k  t1  t2  t3  t4 
I (n  l1 ) I (n  li )]! (t1  t2  t3  t4 )! CtI1SSt(2u, vt3) tI4SL (u ,v )  I LS (u ,v )  I LL (u ,v )
m 1 I ( l1  m )  I ( l i  m ) n 1 I ( l1  n )  I ( l i  n ) k  m  I ( l1  m )  I ( l i  m ) k  n  I ( l1  n )  I ( l i  n )

w0

x 0

y 0

z 0
CwI SS (u ,v) t1 CmI SL1(uI,v(l)1t 2m)  I (li  m)  w CxISS (u ,v )t1wCnILS1(uI ,(vl1)nt3)I (li n)x
CyI LS (u ,v ) t3 [ n 1 I (l1  n)  I (li  n)  x]CkI LLm(u,Iv()l1t 4m)  I (li  m)  y
k  m  I ( l1  m)  I ( li  m)  y ]

CzISL (u ,v )t2 [ m1I (l1m)I (li m)w] CkI LLn(uI,v(l)1tn4 )[
 I (li  n )  z
1
k2
Hence, we define
ISS(u, v), ISL(u, v), ILS(u, v), and ILL(u, v) = The numbers of {1 : u-1}∩{1 : v-1}, {1 :
u-1}∩{v+1 : 2k-i}, {u+1 : 2k-i}∩{1 : v-1}, and {u+1 : 2k-i}∩{v+1 : 2k-i}.
t1, t2, t3, and t4 = the numbers of ties from ISS(u, v), ISL(u, v), ILS(u, v), and ILL(u, v).
If b > a in C ba , vuv = 0.
In displays (1) and (2), we present formulas for the mean and variance of test statistic
under H0. The proof of V0(T) is not presented for the sake of brevity as the arguments
are similar to those presented for the case of ‘‘exactly three ties’’ in the proof of
Theorem 1. Moreover, we illustrate a direct calculation of E0(T) and V0(T) in the
particular case of k  3, and ni  1, 2, or 3 in Table 1. Note that (n1 , n2 , n3 ) = (2, 1,
1
1), E0(T) = 2 and V0(T) = 2.667, which is in agreement with what we obtain using
equation (1) and (2), namely,
E0(T) = 2, and
 1 3
2
v0  1   ni  1.333 ,
 3  i 1
3 1
v
2
i
i 1
 2  1 [
1
1
1
1
1
 0!0!2!(C22  C22 )  2 
 0!1!1!(C12C11  C11C11 )  2 
 0!
24
3
24
3
24
1!1!(C12C11  C11C11 ) 

1
1
1
1
 1!0!1!(C12C11  C11C11 )  2  1!1!1!(C11C12C11  C11C12C11 )
2
3 24
3 24
1
1
1
1
1
1
 1!1!0!(C11C11  C12C11 )  2  1!0!1!(C12C11  C11C11 )  2  1!1!0!(C11
2
3 24
3 24
3 24
C11  C12C11 ) 
31
v
i 1
2
i
1
1
1
  1!1!1!(C13C12C11 )  2 ] ,
2
3 24
3
 2  1 [
2
1
1
1
1
1
1
1
1
1
1
1
2  2  3 2  3 2  3 2  4  2  3 2 
24
3
24
3
24
3
24
3
24
3
24
3
1
1
1
1
1
1
 3  2   3  2   6  2 ]  0.667 ,
24
3
24
3
24
3
1 1
vk2  2  6  (  )  0.667 ,
6 9
V0(T) = 1.333+0.667+0.667=2.667.
2
Download