Hello, dear friend, you can consult us at any time if you have any questions, add WeChat: daixieit

STATS 310/732

2022

Assignment 4


In general, you may use any results given in the course book or lectures to solve an assignment problem (unless the problem is about establishing the result itself).

1.  [18 + (4) marks]    Let X be a random variable with density

f (x; θ) = 2θx exp(-θx2 ),    x > 0, θ > 0.

We wish to use a single value X = x to test the null hypothesis

H0  : θ = 1

against the alternative hypothesis

H1  : θ = 2.

Denote by C  =  {x  : x  < aα } the critical region of a test at the significance level of α = 0.05.

(a)  [2 marks]  Show that the cdf of X is given by F (x) = 1 - exp(-θx2 ),    x > 0.

(b)  [2 marks]  What is the sample space 5, the parameter space Θ and the null parameter

space Θ0  of the test?

(c)  [2 marks]  Compute a0.05 .

(d)  [2 marks]  Compute the power of the test.

(e)  [2 marks]  Compute the probability of Type II error.

(f)  [2 marks]  Show that the test is the most powerful at level α .

(g)  [2 marks]  Show that the test is also the uniformly most powerful (UMP) test when

the alternative hypothesis is replaced with H1 : θ > 1.

(h)  [2 marks]  Show that there exists no UMP test when the alternative hypothesis is

replaced with H1 : θ  1.

(i)  [2 marks]  Extend the above result to the more general situation where X1 , . . . , Xn are an iid sample of the distribution. Show that the UMP test for testing H0 : θ = 1 against H1 : θ > 1 exists and has the critical region of the form

n

Cα  = {x :       xi(2)  < bα }.

i=1

(j)  [(4) marks]  BONUS: Compute the value of bα , when n = 10 and α = 0.05. (Hint: What is the distribution of Xi(2)  and      Xi(2)  under H0 ?)



2.  [12 marks]  Let X1 , . . . , X5  have a multinomial distribution with parameters p1 , . . . , p5 and joint probability function

f (xp) = p1(x)à p2(x)p3(x)gp4(x)p5(x) ,    pi  > 0, xi  > 0, i = 1, . . . , 5

where x = (x1 , . . . , x5 )T , p = (p1 , . . . , p5 )T , n = x1, and p1 = 1.

(a)  [3 marks]    Show that the maximum likelihood estimator  of p is given by x/n.

(b)  [3 marks]   Show that under the assumption p1  = p2  = p3 and p4  = p5 , the maximum

likelihood estimator 0  of p is given by

  ,  ,  ,  , T .

 

(c)  [3 marks]    Consider using - log(LR) to test the null hypothesis

H0  : p1  = p2  = p3  = p4  = p5

against the alternative hypothesis

H1  : p1  = p2  = p3   p4  = p5 .

Let x = (171, 189, 200, 226, 214)T . Compute the p-value of the test.

(d)  [3 marks]    Consider using - log(LR) to test the goodness-of-fit of the model p1  = p2  = p3   p4  = p5 .  Write down H0  and H1  in a form specific to this problem and compute the p-value of the test using the same x as in part (c).


3.  [20 marks]  An experimenter observes independent observations

Y11 , Y12 , . . . , Y1n

Y21 , Y22 , . . . , Y2n

where E(Y1j) = α1 + β1 xj  and E(Y2j) = α2 + β2 xj + γzj , xj  and zj  being the jth values of numerical explanatory variables with sample means 0 and zero empirical correlation, i.e. x = 0, z = 0, xz = 0. Denote by eij  = Yij -E(Yij ) the errors, and assume eij      N(0, σ2 ) for all i and j. Note that σ 2  is common to all errors.

Further,  let  yi    =  (Yi1, Yi2, . . . , Yin )T   and  卡i    =  (ei1, ei2, . . . , ein )T ,  for  i  =  1, 2,  x  = (x1 , x2 , . . . , xn )T , and z =  (z1 , . . . , zn )T .  Also, 0n  and 1n  are vectors of length n with elements of 0, and 1, respectively.

(a)  [4 marks]  Show that this model can be expressed as

 

y = y(y)2(1) =  0(1)n(n)

 

x

0n

 

0n

1n

 

0n

x

α 1

z(0n)        +  卡(卡)2(1) .

γ 

(b)  [4 marks]  Show the least squares estimator of ← = (α1 , β1 , α2 , β2 , γ)T  is

 = Y1 ,  , Y2 ,  , T

where Yi  = n1 Yij .

(c)  [4 marks]  Show that the covariance matrix of ← is

Cov() = σ 2  .(.)  0

 0

0     (xT x)1

0

0

0

0

0

1

n

0

0

0

0

0

(xT x)1 0

0(0)    

0      .(.) .

0      

(d)  [4 marks]  Verify that the estimate of σ 2  is

j(n)=1 {Y1j  - Y1 - 1 (xj  - x)}2 +    j(n)=1 {Y2j  - Y2 - 2 (xj  - x) - (zj  - z)}2

2n - 5                                                        .

(e)  [4 marks]  If one would like to find the least squares estimate under the assumption

that α 1  = α2  and β1  = β2 , one can rewrite the model using only three parameters, e.g., ←   = (α, β, γ)T , in the form

y = X  ←  + 卡,

where  = (1(T) , 2(T))T . Write down the new design matrix X  .


** Extra Questions for STATS 732 Only **

 

4.  [20 marks]  The table below gives the number of failures xi  and the length of operation time ti  (in 1000s of hours), i = 1, . . . , 10, of ten power plant pumps. We assume that the number of failures are independent Poisson random variables, i.e.

Xi |θ, ti  ~ Poisson(θti ),    i = 1, . . . , 10.

with probability density function

f (xi |θ, ti ) = e θt          for xi  = 0, 1, 2, . . . .

where θ is the overall failure rate. As prior distribution for θ, assume the Gamma(α, β) distribution which is the conjugate distribution, with probability density function

f (θ) = θα 1 e βθ

for θ > 0, α > 0, β > 0.

The Gamma(α, β) distribution has mean  and variance β女(α) .

Pump           ti      xi

1

2

3

4

5

6

7

8

9

10

94.50 15.70 62.90 126.00 5.24 31.40 1.05 1.05 2.10 10.50

5

1

5

14

3

19

1

1

4

22

Answer questions a)- f) for general α , β and x1 , . . . , xn , t1 , . . . , tn .

(a)  [2 marks]  Derive the posterior distribution of θ|x1 , . . . , xn .

(b)  [1 marks]  What is the Bayes estimator, dB (x1 , . . . , xn ), under the squared error loss

function?

(c)  [2 marks]  What is the maximum likelihood estimator dMLE (x1 , . . . , xn )?

(d)  [2 marks]    Show that the Bayes estimator in part b) is a weighted average of prior mean and MLE.

(e)  [4 marks]  Calculate the risks of dB (X1 , . . . , Xn ) and dMLE (X1 , . . . , Xn ) under the

squared error loss function.

(f)  [3 marks]  Calculate the Bayes risk of dB  and dMLE .

(g)  [2 marks]  If we have prior information that θ is expected to be about 0.8 with a

standard deviation of 0.4, what is the corresponding Gamma(α, β) prior distribution?

(h)  [2 marks]   With the values for α and β in part g), and the observations given in the

table above, find the posterior probability that θ s 0.15.

(i)  [2 marks]   With the values for α and β in part g), and the observations given in the table above, give a 95% central posterior credible interval for θ .