Two-Sample Likelihood Ratio Tests

April 11, 2017 | Author: Scot Leonard | Category: N/A
Share Embed Donate


Short Description

1 Two-Sample Likelihood Ratio Tests Stat 305 Spring Semester 0 Suppose that X and are two independent, normal random var...

Description

Two-Sample Likelihood Ratio Tests Stat 305 Spring Semester 2011

Suppose that X and Y are two independent, normal random variables, and let fX1; X2 ; : : : ; Xm g and fY1 ; Y2; : : : ; Yng be random samples of size m and n respectively from the random variables X and Y . It is often the case that we would like to test if ¹X = ¹Y , that is, if X and Y have equal means. Also, upon occasion, we need to test if ¾2X = ¾2Y . The technique of likelihood ratios is used to develop tests for both of these problems. The sets of hypotheses for these tests are given below. The test for (I) will be a likelihood ratio test, but the test for (II) will only be an approximate likelihood ratio test. (I) H0 : ¹ X = ¹ Y vs. H1 : ¹X 6= ¹Y where ¾2X and ¾2Y are both unknown but assumed to be equal (II) H0 : ¾ 2X = ¾ 2Y vs. H1 : ¾2X = ¾2Y where ¹ X and ¹Y are both unknown Before any of the tests can be developed, we must identify the likelihood function to be used. Since there are two random samples, what we are really seeking is a joint likelihood function. The pdfs of X and Y are à µ ¶1=2 µ ¶! 1 1 x ¡ ¹X 2 2 fX(x; ¹ X ; ¾X ) = exp ¡ and 2¼¾ 2X 2 ¾X à µ ¶1=2 µ ¶! 1 1 y ¡ ¹Y 2 2 fY (y; ¹Y ; ¾Y ) = exp ¡ . 2¼¾ 2Y 2 ¾Y Therefore, the joint likelihood function is given by µ ¶m=2 µ ¶n=2 1 1 2 2 L(¹X ; ¹Y ; ¾X ; ¾ Y ) = ¢ 2¼¾2X 2¼¾ 2Y à " m µ ¶2 X ¶2#! n µ X 1 xi ¡ ¹ X yj ¡ ¹ Y exp ¡ + . 2 i=1 ¾X ¾Y j=1

(I) Testing for the Equality of the Means We assume that the variances ¾2X and ¾2Y are unknown but equal. (The case when nothing is known about the variances will be addressed later.) Therefore, we will assume that ¾2X = ¾ 2Y = ¾ 2. Formulate H0 and H1 as follows. H0 : ¹ X = ¹ Y = ¹ H1 : ¹ X = 6 ¹Y where ¹ is the common (unknown) value. (It is important to realize that we are not testing whether the means are the same and equal to a speci…c value, just whether they are the same.)

1

Note that ! = f(¹; ¹; ¾ 2; ¾2 ) : ¡1 < ¹ < 1, ¾2 > 0g and - = f(¹X ; ¹ Y ; ¾ 2; ¾ 2) : ¡1 < ¹X < 1, ¡1 < ¹Y < 1, ¾2 > 0g. Over the set !, note that L(¹X ; ¹Y ; ¾2X ; ¾ 2Y ) = L(¹; ¹; ¾2; ¾ 2) Ã " m #! µ ¶(m+n)=2 n X 1 1 X = exp ¡ 2 (xi ¡ ¹)2 + (yj ¡ ¹)2 . 2¼¾2 2¾ i=1 j=1

We must solve the maximization problem

L(¹; ¹; ¾ 2; ¾ 2) (¹;¹;¾ ;¾ )2! 8 ¡ 9 ¢(m+n)=2 1 < 2¼¾ ¢ 2 µ ·m ¸¶ = = max P P . (¹;¹;¾2;¾2 )2! : exp ¡ 12 ; (xi ¡ ¹)2 + nj=1(yj ¡ ¹)2 2¾

L(b !) =

max 2 2

i=1

To solve this maximization, take ln L(¹; ¹; ¾ 2; ¾2 ) and then take partial derivatives. Solve the simultaneous equations @ ln L(¹; ¹; ¾ 2; ¾ 2) = 0, and @¹ @ ln L(¹; ¹; ¾ 2; ¾ 2) = 0. @¾2 (The details are straightforward and therefore omitted.) We obtain the solutions Ãm ! n X X 1 ¹ = b x + y , and n + m i=1 i j=1 j Ãm ! n X X 1 2 2 2 ¾! = b (xi ¡ b ¹) + (yj ¡ b ¹) . n + m i=1 j=1

It is easy to establish that L(¹; ¹; ¾ 2; ¾ 2) achieves a maximum at the point (b ¹; ¹ b; b ¾2! ; ¾b2! ) 2 !. Evaluating the likelihood function at this point to obtain the maximum value, we obtain L(b !) = L(b ¹; b ¹; ¾b2! ; b ¾2! ) Ã " m #! µ ¶(m+n)=2 n X 1 1 X = exp ¡ 2 (xi ¡ b ¹ )2 + (yj ¡ b ¹ )2 2¼b ¾ 2! 2b ¾ ! i=1 j=1 µ ¶(m+n)=2 µ ¶ 1 m +n = exp ¡ 2 2 2¼b ¾! µ ¡1 ¶(m+n)=2 e = . 2¼b ¾ 2!

b is given by Therefore, the numerator, L(b !), of the ratio L(b !)=L(-) µ ¡1 ¶(m+n)=2 e L(b !) = . 2¼b ¾2! 2

Turning now to the set -, L(¹X ; ¹Y ; ¾2X ; ¾ 2Y ) = L(¹X ; ¹Y ; ¾ 2; ¾2 ) µ ¶(m+n)=2 1 = ¢ 2¼¾2 Ã " m #! n X 1 X exp ¡ 2 (xi ¡ ¹ X) 2 + (yj ¡ ¹Y )2 . 2¾ i=1 j=1

Therefore, we must now solve the maximization problem b = L(-)

L(¹X ; ¹ Y ; ¾ 2; ¾ 2) (¹X ;¹Y ;¾ ;¾ )28 ¡ 9 ¢(m+n)=2 1 < 2¼¾ ¢ 2 µ ·m ¸¶ = = max P P . 1 ; (¹X ;¹Y ;¾2;¾2 )2- : exp ¡ 2 (xi ¡ ¹ X) 2 + nj=1(yj ¡ ¹ Y )2 2¾ max 2 2

i=1

If we take ln L(¹X ; ¹Y ; ¾2 ; ¾2) and then take partial derivatives and solve the equations @ ln L(¹X ; ¹Y ; ¾2 ; ¾2) = 0, @¹X @ ln L(¹X ; ¹Y ; ¾2 ; ¾2) = 0, and @ ¹Y @ ln L(¹X ; ¹Y ; ¾2 ; ¾2) = 0, @¾ 2 we obtain the solutions bX = x, ¹ ¹Y = y, and b b2¾

1 = n+m

Ã

m n X X 2 (xi ¡ x) + (yj ¡ y)2 i=1

j=1

!

.

As before, it is easily shown that L(¹X ; ¹ Y ; ¾ 2; ¾2 ) achieves a maximum at the point (b ¹X ; b ¹Y ; ¾2- ; ¾b2- ) 2 -. Evaluating the likelihood function at this point, we obtain b b = L(b L(-) ¹X ; b ¹Y ; b ¾2- ; b ¾2- ) Ã " m #! µ ¶(m+n)=2 n X 1 1 X = exp ¡ 2 (xi ¡ x) 2 + (yj ¡ y)2 2¼b ¾ 22b ¾- i=1 j=1 µ ¶(m+n)=2 µ ¶ 1 m+n = exp ¡ 2 2 2¼b ¾µ ¡1 ¶(m+n)=2 e = . 2¼b ¾ 2-

b of the ratio L(b b is Therefore the denominator, L(-), !)=L(-) µ ¡1 ¶(m+n)=2 e b = L(-) . 2¼b ¾23

Putting it all together, we get that ³ ¡1 ´(m+n)=2 e µ 2 ¶(m+n)=2 L(b !) 2¼b ¾2! ¾b = ³ = ´ (m+n)=2 b ¾b2! L(-) e¡1 2¼b ¾2-

0

Ã

m P

n P

i=1

j=1

! 1(m+n)=2

1 (xi ¡ x)2 + (yj ¡ y)2 C B n+m B C i=1 j=1 C Ã ! = B B C m n P P @ 1 A 2 2 (xi ¡ b ¹) + (yj ¡ ¹ b) n+m

.

Some algebra must be done to simplify the above expression. To this end, we work with the denominator …rst. In particular, m m X X 2 (xi ¡ b ¹) = [(xi ¡ x) + (x ¡ b ¹)] 2 i=1

i=1 Ã ! m X = (xi ¡ x)2 + m(x ¡ b ¹ )2 (the middle terms will cancel out)

= = = =

à i=1 ! µ ¶ m X mx + ny 2 2 (xi ¡ x) + m x ¡ m+n à i=1 ! µ ¶ m X mx + nx ¡ mx ¡ ny 2 2 (xi ¡ x) + m m+n à i=1 ! µ ¶ m X n(x ¡ y) 2 2 (xi ¡ x) + m m+n i=1 à m ! X mn 2(x ¡ y)2 (xi ¡ x)2 + . 2 (m + n) i=1

Likewise (details omitted), we have that à n ! n X X m2n(x ¡ y)2 (yj ¡ b ¹) 2 = (yj ¡ y)2 + . (m + n)2 j=1 j=1 Therefore, b2! ¾

1 = n+m

Ã

m n X X 2 (xi ¡ b ¹) + (yj ¡ b ¹)2 i=1

j=1

à n ! ! 2 2 X mn2(x ¡ y)2 m n(x ¡ y) + + (yj ¡ y)2 + 2 (m + n) (m + n)2 i=1 j=1 Ãm ! n X X 1 mn2 (x ¡ y)2 m2n(x ¡ y)2 = (xi ¡ x)2 + (yj ¡ y)2 + + n + m i=1 (m + n)3 (m + n)3 j=1 1 = n+m

ÃÃ

m X (xi ¡ x)2

!

!

4

mn(x ¡ y)2 (m + n) (m + n)3 mn(x ¡ y)2 = b ¾2- + . (m + n)2 = ¾ b2- +

Continuing with the derivation, we get µ 2 ¶(m+n)=2 L(b !) ¾b = b ¾2! b L( -) Ã !(m+n)=2 ¾2b = 2 ¾b2- + mn(x¡y) (m+n)2 0 1(m+n)=2 1 (divide numerator and A = @ mn(x¡y)2 denominator by b ¾2- ) 1 + ¾b2 (m+n)2 0 1¡(m+n)=2 2 = @1 + 0

B B = B B1 + @ 0

mn(x¡y) (m+n)2 ¾b2-

0

mn(x¡y)2 (m+n)2

i=1

i=1

B B = B B1 + @

1¡(m+n)=2

C C Ã !C C m n P P A 1 2+ 2 (x ¡ x) (y ¡ y) i j n+m

B B = B B1 + ÃP m @ 0

A

j=1

1¡(m+n)=2

C C !C C n P A (xi ¡ x) 2 + (yj ¡ y)2 mn(x¡y)2 m+n

(cancel the m + n terms)

j=1

1¡(m+n)=2

C C Ã !C C m n P P A m+n¡2 2 2 (xi ¡ x) + (yj ¡ y) m+n¡2 mn(x¡y)2 m+n

i=1

j=1

92 1¡(m+n)=2 > > p mn = C B (x¡y) m+n B C v " # u B C u m n > > P P B C > t 1 2+ 2 > : (x ¡x) (y ¡y) ; i j B m+n¡2 C i=1 j=1 B C = B1 + C B m+n¡2 C B C B C B C @ A =

µ

8 > > <

t2 1+ m+n¡2

¶¡(m+n)=2

5

(multiply the denominator by 1)

where t= v u u t

1 m+n¡2

"

p

m P

i=1

mn m+n (x

¡ y)

(xi ¡ x)2 +

n P

j=1

(yj ¡ y)2

#.

To sum up, we have shown that µ ¶¡(m+n)=2 L(b !) t2 = 1+ , b m+n¡2 L(-)

and so setting the ratio less than k, we obtain µ ¶¡(m+n)=2 t2 1+ (m + n ¡ 2)

µ

1 k2=(m+n)

¶ ¡1 .

Therefore, taking the square root of both sides, s µ ¶ 1 jtj > (m + n ¡ 2) ¡ 1 = k¤ . k 2=(m+n) Before constructing the test, the only issue left to be addressed is the distribution of the statistic p mn m+n (X ¡ Y ) v " # u m n u 1 P P t (Xi ¡ X)2 + (Yj ¡ Y )2 m+n¡2 i=1

j=1

under H0. (That is, when ¹X = ¹Y = ¹.) We can rewrite the statistic as p mn p mn (X ¡ Y ) m+n m+n (X ¡ Y ) v q = " # u 1 2 + (n ¡ 1)S 2 ] m n [(m ¡ 1)SX u 1 P P Y m+n¡2 t 2 2 (Xi ¡ X) + (Yj ¡ Y ) m+n¡2 i=1

j=1

6

p

= r

¾2 m+n¡2

= r

1 m+n¡2

1 ¾

mn m+n (X

h

p

h

¡Y )

(m¡1)S2X ¾2 mn (X m+n (m¡1)S2X ¾2

+

(n¡1)S2Y ¾2

¡Y ) +

(n¡1)S2Y ¾2

i i.

Let us …rst consider the numerator of this last expression. Call it Z. Since X and Y are both normal with mean ¹ and variance ¾ 2, the random variable X ¡ Y is normal with mean 0 and variance ¾ 2(1=m + 1=n) = ¾ 2(m + n)=mn. Therefore, the mean of Z is 0, and the variance of Z is µr ¶2 mn 1 ¾2(m + n) V ar(Z) = = 1. m +n ¾2 mn So we see that the numerator is simply a standard normal random variable. By previous results, we know that 2 (m ¡ 1)SX (n ¡ 1)SY2 and ¾2 ¾2

are Â2 random variables with m ¡ 1 and n ¡ 1 degrees of freedom respectively. By independence, 2 (m ¡ 1)SX (n ¡ 1)SY2 + ¾2 ¾2

p is Â2m+n¡2 . Therefore, the statistic is of the form Z= V =(m + n ¡ 2) where V is Â2m+n¡2 . Since Z and V are also independent, p mn m+n (X ¡ Y ) v " # v tm+n¡2. u m n u 1 P P t (Xi ¡ X)2 + (Yj ¡ Y )2 m+n¡2 i=1

j=1

It should be noted that the test statistic is written in a variety of di¤erent ways depending on the author. For example, if we set " m # n X X 1 Sp2 = (Xi ¡ X)2 + (Yj ¡ Y )2 , m + n ¡ 2 i=1 j=1 then we can write the statistic as p mn p mn m+n (X ¡ Y ) m+n (X ¡ Y ) v = " # u Sp m n u 1 P P t 2 2 (Xi ¡ X) + (Yj ¡ Y ) m+n¡2 i=1

j=1

=

X ¡Y q . Sp m1 + 1n

The quantity Sp2 is sometimes referred to as the pooled variance, and consequently, Sp is called the pooled standard deviation. We can now formulate the test. At level ®,

7

® = P (rejecting H0 when H0 is true) 0 1 0 X ¡ Y X ¡Y = P@ q < ¡k ¤A + P @ q 1 1 Sp m + n1 Sp m +

1 n

1

> k ¤A .

Assigning equal probabilities to the two tails of the t distribution, we have that k ¤ = t®=2;m+n¡2. We have derived the standard form of the decision rule for this test.

Decision Rule Reject H0 if

X¡Y p 1

Sp

1 m+ n

> t®=2;m+n¡2 or

Sp

8

X¡Y p 1

1 m +n

< ¡t®=2;m+n¡2.

We summarize all our computations and derivations in the following table.

Summary for (I) Test

H0 : ¹X = ¹Y = ¹ vs. H1 : ¹X 6= ¹Y where ¾ 2X and ¾2Y are both unknown but assumed to be equal

!

f(¹; ¹; ¾2 ; ¾2) : ¡1 < ¹ < 1, ¾2 > 0g

-

f(¹ X; ¹ Y ; ¾ 2; ¾ 2) : ¡1 < ¹X < 1, ¡1 < ¹Y < 1, ¾ 2 > 0g

L(b !)

b L(-)

b L(b !)=L(-) Test Statistic

Decision Rule

³

e ¡1 2¼b ¾2!

b 2! = ¾ ³

e¡1 2¼b ¾2-

b 2- = ¾ ³

1+

t=

v u u t

´(m+n)=2 1 n+m

Ã

where

m P

i=1

´(m+n)=2 1 n+m

Ã

1 m+n ¡2

1 m+n¡2

"

(xi ¡ x)2 +

´¡(m+n)=2

"

p

m P

i=1

j=1

(Xi

Reject H0 if

n P

(yj ¡y) 2

j=1

n P

j=1

X¡Y p 1

1 m +n

!

!

where

(x i ¡x)2 +

¡X)2 +

Sp

(yj ¡ y)2

mn m+n (x¡y)

m+n (X¡Y )

i=1

n P

j=1

p mn m P

(yj ¡ b ¹)2

where

i=1

t2 m+n¡2

v u u t

m P

(xi ¡ b ¹)2 +

n P

(Yj ¡Y

)2

#

#

=

=

Sp

sp

px¡y 1 m

X¡Y p 1

1 m +n

> t®=2;m+n¡2 or

Sp

+ 1n

v tm+n¡2

X¡Y p 1

1 m +n

< ¡t®=2;m+n¡2.

The preceding test was obtained under the somewhat restrictive assumption that the variances were unknown but equal. If nothing is known about the variances, then the problem is much harder. In fact, the problem of testing the equality of two means when the variances are unknown is called the Fisher-Behrens Problem and is currently unsolved.

9

(II) Testing for the Equality of the Variances We assume that nothing is known about the means ¹X and ¹Y . Formulate the hypotheses H0 and H1 as follows. H0: ¾ 2X = ¾ 2Y = ¾ 2 H1: ¾ 2X 6= ¾2Y The quantity ¾2 is the common (unknown) variance. (As before, it is important to realize that we are not testing whether the variances are the same and equal to a speci…c value, just whether they are the same.) Note that ! = f(¹ X; ¹ Y ; ¾ 2; ¾ 2) : ¡1 < ¹ X < 1, ¡1 < ¹ Y < 1, ¾ 2 > 0g and - = f(¹ X ; ¹Y ; ¾2X ; ¾2Y ) : ¡1 < ¹X < 1, ¡1 < ¹Y < 1, ¾2X > 0, ¾ 2Y > 0g. Over the set !, note that L(¹X ; ¹Y ; ¾2X ; ¾2Y ) = L(¹X ; ¹Y ; ¾2 ; ¾2) Ã "m #! µ ¶(m+n)=2 n X 1 1 X = exp ¡ 2 (xi ¡ ¹X )2 + (yj ¡ ¹Y )2 . 2 2¼¾ 2¾ i=1 j=1 We must solve the maximization problem

L(¹ X ; ¹Y ; ¾2; ¾ 2) 8¡ 9 ¢(m+n)=2 1 < 2¼¾ ¢ 2 µ ·m ¸¶ = P P = max . n 2 2 (¹X ;¹Y ;¾2;¾2 )2! : exp ¡ 12 ; (x ¡ ¹ ) + (y ¡ ¹ ) i j X Y j=1 2¾

L(b !) =

max

(¹X ;¹Y ;¾2;¾2 )2!

i=1

To solve this maximization, take ln L(¹X ; ¹ Y ; ¾ 2; ¾2 ) and then take partial derivatives. Solve the simultaneous equations @ ln L(¹X ; ¹Y ; ¾2 ; ¾2) = 0, @¹X @ ln L(¹X ; ¹Y ; ¾2 ; ¾2) = 0, and @ ¹Y @ ln L(¹X ; ¹Y ; ¾2 ; ¾2) = 0. @¾ 2 (As before, the details are straightforward and omitted.) We obtain the solutions bX = x, ¹ ¹Y = y, b ¾b2

1 = n+m

Ã

m n X X 2 (xi ¡ x) + (yj ¡ y)2 i=1

j=1

10

!

.

It is easy to establish that L(¹ X ; ¹Y ; ¾2; ¾ 2) achieves a maximum at the point (b ¹ X; ¹ bY ; ¾b2; ¾b2) 2 !. Evaluating the likelihood function at this point to obtain the maximum value, we obtain L(b !) = L(b ¹X ; b ¹Y ; b ¾2; ¾b2) Ã " m #! µ ¶(m+n)=2 n X 1 1 X = exp ¡ 2 (xi ¡ x) 2 + (yj ¡ y)2 2 2¼b ¾ 2b ¾ i=1 j=1 µ ¶(m+n)=2 µ ¶ 1 m+n = exp ¡ 2 2 2¼b ¾ µ ¡1 ¶(m+n)=2 e = . 2¼b ¾2

b is given by Therefore, the numerator, L(b !), of the ratio L(b !)=L(-) L(b !) =

µ

e¡1 2¼b ¾2

¶(m+n)=2

.

Now consider maximizing the likelihood function on the set -. Over -, µ ¶m=2 µ ¶n=2 1 1 2 2 L(¹X ; ¹Y ; ¾X ; ¾ Y ) = ¢ 2¼¾2X 2¼¾ 2Y Ã " m µ ¶ ¶ #! n µ 1 X xi ¡ ¹ X 2 X yj ¡ ¹ Y 2 exp ¡ + . 2 i=1 ¾X ¾Y j=1 Therefore, we must now solve the maximization problem b = L(-)

L(¹X ; ¹Y ; ¾2X ; ¾ 2Y ) 8 ³ ´m=2 ³ ´n=2 1 > < 2¼¾1 2 ¢ 2 Y µX · m 2¼¾ ¸¶ ³ ´ = max P xi¡¹X 2 Pn ³ yj ¡¹Y ´2 1 (¹X ;¹Y ;¾2X ;¾2Y )2- > : exp ¡ 2 + j =1 ¾X ¾Y max

(¹X ;¹Y ;¾2X ;¾2Y )2-

i=1

9 > = > ;

.

If we take ln L(¹X ; ¹Y ; ¾2X ; ¾ 2Y ) and then take partial derivatives and solve the equations @ ln L(¹X ; ¹Y ; ¾2X ; ¾ 2Y ) @¹X @ ln L(¹X ; ¹Y ; ¾2X ; ¾ 2Y ) @ ¹Y @ ln L(¹X ; ¹Y ; ¾2X ; ¾ 2Y ) @¾2X @ ln L(¹X ; ¹Y ; ¾2X ; ¾ 2Y ) @¾ 2Y

= 0, = 0, = 0, and = 0,

11

we obtain the solutions bX = x, ¹ ¹ Y = y, b m 1 X ¾2X = b (xi ¡ x)2 , and m i=1 n

¾ 2Y b

1X = (y ¡ y)2 . n j=1 j

It is easily shown that L(¹X ; ¹ Y ; ¾ 2X ; ¾2Y ) achieves a maximum at the point (b ¹ X; ¹ bY ; ¾b2X ; b ¾2Y ) 2 -. Evaluating the likelihood function at this point, we obtain µ ¶m=2 µ ¶n=2 1 1 2 2 b = L(b L(-) ¹X ; b ¹Y ; b ¾X ; b ¾Y ) = ¢ 2¼b ¾2X 2¼b ¾ 2Y Ã " m µ ¶2 X ¶2 #! n µ 1 X xi ¡ x yj ¡ y exp ¡ + 2 i=1 ¾X b ¾Y b j=1 µ ¶m=2 µ ¶n=2 µ ¶ 1 1 m+n = exp ¡ 2 2¼b ¾ 2X 2¼b ¾2Y µ ¡1 ¶(m+n)=2 µ ¶m=2 µ ¶n=2 e 1 1 = . 2 2¼ ¾X b ¾2Y b b of the ratio L(b b is Therefore the denominator, L(-), !)=L(-) µ ¡1 ¶(m+n)=2 µ ¶m=2 µ ¶n=2 1 1 b = e L(-) . 2 2¼ ¾bX ¾2Y b Forming the ratio, we get that ³ ¡1 ´(m+n)=2 e L(b !) 2¼b ¾2 = ¡ ¢ ³ ´m=2 ³ b L(-) e ¡1 (m+n)=2 1 ¾2X b



1 ¾2Y b

´n=2

¡ 2 ¢m=2 ¡ 2 ¢ n=2 ¾X b ¾bY = ¡ 2¢ (m+n)=2 ¾b !n=2 µ m ¶m=2 Ã n P 1 P 1 (xi ¡ x)2 (yj ¡ y) 2 m n = Ã

i=1

1 m+n

For convenience, let

Ã

m P

i=1

j=1

(xi ¡ x)2 +

n P

j=1

(yj ¡ y)2

m n X X 2 a= (xi ¡ x) and b = (yj ¡ y)2. i=1

j=1

12

!!(m+n)=2 .

Continuing with the above derivation, we have that ¡ 1 ¢ m=2 ¡ 1 ¢n=2 a b m¡m=2n¡m=2am=2bm=2 m n = ¡ 1 ¢(m+n)=2 (m + n)¡(m+n)=2 (a + b)(m+n)=2 n+m (a + b)

(m + n)(m+n)=2 (a=b) m=2 (divide numerator and ¢ ¡ ¢ m=2 m=2 (m+n)=2 a denominator by b(m+n)=2) m n 1+ b h¡ ¢ ³ a=(m¡1) ´im=2 m¡1 (m+n)=2 (m + n) n¡1 b=(n¡1) = ¢³ ³ ´´(m+n)=2 m=2 m=2 ¡ ¢ m n a=(m¡1) m¡1 1 + n¡1 b=(n¡1) £¡ m¡1 ¢ ¤m=2 µ ¶ (m + n)(m+n)=2 a=(m ¡ 1) n¡1 x = ¢¡ where x = . ¡ ¢ ¢(m+n)=2 mm=2 nm=2 b=(n ¡ 1) 1 + m¡1 x n¡1 =

Summing up, we have that

£¡ m¡1 ¢ ¤m=2 L(b !) (m + n)(m+n)=2 n¡1 x = ¢ ¡ ¡ ¢ ¢ (m+n)=2 , x ¸ 0. b mm=2n m=2 L(-) 1 + m¡1 n¡1 x

The next step would be to set the ratio less than k and then to determine the critical region. Before doing so, we must investigate the shapes of the graphs of the ratio. The graphs of b for m = 7 and n = 19 and for m = 37 and n = 13 are given below. g(x) = L(b !)=L(-)

b for m = 7 and n = 19 g(x) = L(b !)=L(-)

b for m = 37 and n = 13 g(x) = L(b ! )=L(-)

All the graphs of the functions g(x) have the following properties. ² g(0) = 0 and lim g(x) = 0 x!1

² g 0 (x) = 0 for x = x0 =

m(n¡1) n(m¡1)

13

² g 0 (x) > 0 for x < x0 and g 0 (x) < 0 for x > x0 ² g(x) is maximized for x = x0 and g(x0) = 1 On the basis of these observations, if g(x) < k for some k, then there exists x1 and x2 such that x < x1 and x > x2. So, for our case, the critical region is described by a=(m ¡ 1) a=(m ¡ 1) < x1 or > x2 . b=(n ¡ 1) b=(n ¡ 1)

But recall that

a=(m ¡ 1) = b=(n ¡ 1)

1 m¡1 1 n¡1

m P

(xi ¡ x)2

i=1 n P

j=1

.

(yj ¡ y)2

Under H0, we assumed that ¾2X = ¾2Y = ¾ 2. Therefore, by previous results, we know that the statistic m 1 X (m ¡ 1)S2X 2 (X ¡ X) = i ¾2 i=1 ¾2 is a Â2m¡1 . Similarly,

n 1 X (n ¡ 1)SY2 2 (Y ¡ Y ) = j ¾2 j =1 ¾2

is Â2n¡1. Consequently, 1 m¡1 1 n¡1

m P

i=1 n P

(Xi ¡ X)2 (Yj ¡ Y )2

=

S2X v Fm¡1;n¡1 . SY2

j=1

We can now formulate the test. Note that the test will be an approximate likelihood ratio test. At level ®, ® = P (rejecting H0 when H0 is true) 2 2 = P (SX =SY2 < x1 ) + P (SX =SY2 > x2). Assigning equal probabilities to the two tails of the F distribution, we have that x1 = F1¡®=2;m¡1;n¡1 and x2 = F®=2;m¡1;n¡1. We have derived the standard form of the decision rule for this test.

Decision Rule 2 2 Reject H0 if SX =SY2 < F1¡®=2;m¡1;n¡1 or SX =SY2 > F®=2;m¡1;n¡1.

14

We summarize all our computations and derivations in the following table.

Summary for (II) Test

H0: ¾2X = ¾2Y = ¾ 2 vs. H1: ¾ 2X 6= ¾ 2Y where nothing is known about the means of X and Y

!

f(¹X ; ¹Y ; ¾2 ; ¾2 ) : ¡1 < ¹X < 1, ¡1 < ¹Y < 1, ¾2 > 0g

-

f(¹X ; ¹Y ; ¾2X ; ¾ 2Y ) : ¡1 < ¹X < 1, ¡1 < ¹Y < 1, ¾2X > 0, ¾ 2Y > 0g

L(b !)

b L(-) b L(b ! )=L(-)

³

e¡1 2¼¾ b2

b2 = ¾ ³

e¡1 2¼

´(m+n)=2 1 n+m

Ã

m P

where

i=1

´(m+n)=2 ³

b2X = ¾

1 m

m P

i=1

´m=2 ³

j=1

(yj ¡ y)2

!

´n=2

where n P (xi ¡ x)2 and ¾ b2Y = n1 (yj ¡ y)2

(m+n) (m+n)=2 mm=2nm=2

x = s2X =s 2Y

(xi ¡ x)2 +

n P

1 ¾ b2X

1 ¾ b2Y

j=1

m=2

¢

[( m¡1 n¡1 )x ] (m+n)= 2 where m¡1 (1+( n ¡1 )x)

Test Statistic

2 SX =SY2 v F m¡1;n¡1

Decision Rule

2 =S 2 < F 2 2 Reject H0 if SX 1¡®=2;m¡1;n¡1 or S X =S Y > F®=2;m¡1;n¡1. Y

15

View more...

Comments

Copyright � 2017 SILO Inc.