Stat 411 { Homework 10 Solutionshomepages.math.uic.edu/.../Homework0/411_hw10_soln.pdf · Stat 411...

2

Click here to load reader

Transcript of Stat 411 { Homework 10 Solutionshomepages.math.uic.edu/.../Homework0/411_hw10_soln.pdf · Stat 411...

Page 1: Stat 411 { Homework 10 Solutionshomepages.math.uic.edu/.../Homework0/411_hw10_soln.pdf · Stat 411 { Homework 10 Solutions 1.(a)The exponential distribution is an exponential family

Stat 411 – Homework 10 Solutions

1. (a) The exponential distribution is an exponential family and, therefore, has mono-tone likelihood ratio property in T =

∑ni=1Xi. So, in this case, the most-

powerful test will reject H0 : θ = 2 in favor of H1 : θ = 1 iff T is less thana cutoff. To find the cutoff, we must use the fact that, if H0 is true, then Tis a Gamma(n, 2) random variable. Therefore, the size-α most powerful testrejects H0 iff T ≤ γn,2,α, where γn,2,α is such that Pθ=2{T ≤ γn,2,α} = α. Forexample, if n = 10 and α = 0.05, then you can find γ10,2,0.05 in R with thecommend qgamma(0.05, shape=10, scale=2).

(b) The likelihood for Unif(0, θ) is L(θ) = θ−nI[0,θ](X(n)) where X(n) is the largestorder statistic. According to Neyman–Pearson, the most powerful tests rejectsH0 : θ = 2 in favor of H1 : θ = 1 iff

L(2)

L(1)=(1

2

)n I[0,2](X(n))

I[0,1](X(n))is too small.

Careful inspection of this expression reveals that it can only be two differentvalues:

L(2)

L(1)=

{2−n if X(n) ≤ 1

∞ if X(n) > 1.

Clearly, H1 is wrong if X(n) > 1, so the infinite value makes sense. But the factthat there’s only one finite value means we have (essentially) no control overthe size of the test. That is, the most powerful test rejects H0 iff X(n) ≤ 1,and its size is

P2(X(n) ≤ 1) = P2(X1 ≤ 1)n = 2−n.

If n is five or more, then this is less than 0.05. But the good thing is that thepower of this test when θ = 1 is P1(X(n) ≤ 1) = 1!

2. (a) In this case, L(θ) = θn(∏n

i=1Xi)θ−1 = θne(θ−1)

∑ni=1 logXi . Neyman–Pearson

says the most powerful test of H0 : θ = 1 versus H1 : θ = 2 rejects H0 iff

L(1)/L(2) = 2−ne−∑n

i=1 logXi is too small.

This quantity is too small iff −∑n

i=1 logXi is, itself, too small. So the test canbe expressed in terms of T = −

∑ni=1 logXi. To figure out what “too small”

means in this case, follow the hint which says that, if H0 : θ = 1 is true, thenT has a Gamma(n, 1) distribution. Therefore, the most powerful size-α testrejects H0 iff T ≤ γn,1,α, where this cutoff is as defined in Problem #1.

(b) Let θ1 > 1. The likelihood ratio is given by

L(1)/L(θ1) = θ−n1 e−(θ1−1)∑n

i=1 logXi .

Since θ1−1 > 0, we see, just as in part (a), that the likelihood ratio is increasingin T = −

∑ni=1 logXi. Therefore, it has the monotone likelihood ratio property

in T and, hence, the test described in part (a) is actually uniformly mostpowerful for H0 : θ = 1 versus H1 : θ > 1.

1

Page 2: Stat 411 { Homework 10 Solutionshomepages.math.uic.edu/.../Homework0/411_hw10_soln.pdf · Stat 411 { Homework 10 Solutions 1.(a)The exponential distribution is an exponential family

3. Problem 8.2.6 HMC. By the monotone likelihood ratio property of N(0, θ), where θ isthe variance, we know that (i) for H0 : θ = θ0 versus H1 : θ > θ0, the uniformly mostpowerful test rejects H0 iff

∑ni=1X

2i is too big, and (ii) for H0 versus H1 : θ < θ0,

the uniformly most powerful test rejects if∑n

i=1X2i is too small. Test (i) has the

largest possible power function on the interval (θ0,∞) and test (ii) has the largestpossible power function on (0, θ0). Since there can be no size-α test which has powerfunction greater than the maximum of these two power functions on (0,∞), therecan be no uniformly most powerful test of H0 versus H1 : θ 6= θ0.

4. (Graduate only) LetX1, . . . , Xniid∼ Beta(θ, 1); that’s the distribution in Problem #2.

We’re still interested in the quantity T = −∑n

i=1 logXi, but when θ > 1. In thiscase, we need to be a bit more careful about the distribution of T . First, it turnsout that − logX1 has an exponential distribution with mean θ−1.1 In other words,−θ logX1 ∼ Exp(1). Then it follows from before that θT ∼ Gamma(n, 1). Recallthat the test from Problem #2(a) rejects H0 iff T ≤ γn,1,α. So then the powerfunction at θ is

pow(θ) = Pθ(T ≤ γn,1,α) = Pθ(θT ≤ θγn,1,α) = P{Gamma(n, 1) ≤ θγn,1,α},

that is, the probability that a Gamma(n, 1) random variable is no more than θγn,1,α.In R, you may obtain a graph of this function with the following code:

n <- 10

alpha <- 0.05

pow <- function(theta) {

g <- qgamma(alpha, shape=n, scale=1)

out <- pgamma(theta * g, shape=n, scale=1)

return(out)

}

curve(pow, xlim=c(1,4), lwd=2, xlab=expression(theta), ylab="Power")

1To see this, define Y = − logX1 and use the transformation formula to find the PDF of Y ; you’llsee that it’s of the form of an exponential distribution.

2