Please have your name, student number, and your tutor’s name clearly displayed on the first page.
Instructions: Questions labelled with ‘(R)’ require use of R. Please provide appropriate R commands and their output, along with sufficient explanation and interpretation of the output to demonstrate your understanding. Such R output should be presented in an integrated form together with your explanations. All other questions should be completed without reference to any R commands or output, except for looking up quantiles of distributions where necessary. Make sure you give enough explanation so your tutor can follow your reasoning if you happen to make a mistake. Please also try to be as succinct as possible. Each assignment will include marks for good presentation.
1. (R) An interior automotive supplier places several electrical wires in a harness. A pull test measures the force required to pull spliced wires apart. A customer requires that each wire that is spliced into the harness withstand a pull force of 20 pounds. Let X be a random variable representing the pull force required to pull a spliced wire apart. The following are 20 observations of X:
28.8 24.4 30.1 25.6 26.4 23.9 22.1 22.5 27.6 28.1 20.8 27.7 24.4 25.1 24.6 26.3 28.2 22.2 26.3 24.4
(a) Give basic summary statistics for these data and produce a box plot. Briefly comment on center, spread and shape of the distribution.
(b) Assuming a normal distribution (with unknown mean and variance) for X, compute maximum likelihood estimates for the parameters.
(c) Draw a density histogram and superimpose a pdf for a normal distribution using the estimated parameters.
(d) Draw a QQ plot to compare the data against the fitted normal distribution. Include a reference line. Comment on the fit of the model to the data.
(e) Assume a normal distribution (with unknown mean and variance) for X. Find a one-sided 95% confidence interval that is a lower bound for the mean of X, and answer the question that whether the supplier meets the customer’s requirement.
2. Let X1, . . . , Xn be a random sample from a discrete distribution with the following pmf:
x
0 1 2 3
p(x)
1 − θ θ/2 θ/4 θ/4
(a) (i) Find E(X1) and var(X1).
(ii) Find the method of moments estimator (MME) ˜θ of θ.
(iii) Is ˜θ unbiased for θ? Explain why or why not.
(iv) Find the variance of ˜θ.
(b) Let F0, F1, F2 and F3 denote the sample frequencies of 0, 1, 2 and 3, respectively. That is, Fk = Pn i=1 I(Xi = k) for k = 0, 1, 2, 3.
(i) Find the likelihood function in terms of F0, F1, F2 and F3.
(ii) Show that the maximum likelihood estimator (MLE) of θ is
ˆθ = 1 − F0/n.
Hint: use the fact that F0 + F1 + F2 + F3 = n.
(iii) Find the sampling distribution of F0.
(iv) Is ˆθ unbiased for θ? Explain why or why not.
(v) Find the variance of ˆθ.
(vi) Find an approximate 95% confidence interval for θ based on ˆθ.
3. Let X1, . . . , Xn be a random sample from the inverse Gaussian distribution, IG(µ, λ), whose pdf is:
f(x | µ, λ) = λ 2πx 3 1/2 exp −λ(x − µ) 2 2µ2x , x > 0.
(a) Show that the MLE of µ and λ are µˆ = X¯ and
λˆ =n P i (X −1 i − X¯ −1 ) .
(b) It is known that nλ/λˆ ∼ χ 2 n−1 . Use this to derive a 100 · (1 − α)% CI for λ.
(c) (R) Consider the following dataset:
10.6, 91.3, 51.7, 2.2, 3.8, 6.0, 17.8, 131.8, 31.0, 4.2, 13.7, 10.2, 9.9, 4.3, 5.6, 12.9, 42.0, 14.1, 3.8, 9.3, 2.6, 27.6, 1.7, 7.0, 2.1, 1.5, 7.5, 2.5, 2.4, 51.9
(i) Assuming an inverse Gaussian distribution is an appropriate model for these data, compute the maximum likelihood estimate of λ and give a 95% CI for λ.
(ii) Draw a QQ plot to compare these data to the fitted inverse Gaussian distribution, IG(µˆ, λˆ). Is this model appropriate for these data?
Hint: Quantiles for the inverse Gaussian distribution may be computed using the qinvgauss function in the statmod R package.