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

ST227 PROJECT MOCK PAPER.

Question  1. The lifetime of a mechanical system is modelled by the following mortality intensity1 :

µ(t) ≡ λ,    t ≥ 0,λ = 10 1 .

(1) Define in R the survival probability function (t,x) → tpx and calculate the probability of surviving the next 5 years for a 15-year-old system.2

General wear and tear in mechanical systems mean the memoryless property of constant mortality is a questionable one. We overcome that by introducing a time-dependent term:

(t) = λ + γ log(log(e + t)),    t ≥ 0,    λ = 10 1 ,γ = 1.5

(2) Consider a 15-year-old machine, of which the remaining lifetime T15  follows the mor- tality function  .

(a) Define in R the density function for T15 . This definition may involve a numerical integral.

(b) Calculate the expected remaining lifetime for this individual.

(c) Define in R the cumulative distribution function of T15 .   This definition may involve a numerical integral. Discuss how you would find the 95-th percentile of T15 .3

Question 2. This questions is divided into parts. Both parts use the same data set of fully observed lifetimes given below:

64   75   29   45   67   65   77   90   65   55

80   67   72   46   64   28   68   75   49   94

(1) Let us suppose that this data set comes from a gamma distribution with shape-rate parametrisation, i.e:

f(x|α,β) = xα 1 e βx ,    x > 0.                                        (1)

(a) Using the results:

α                       α

β ,                     β 2 ,

derive the method of moment estimators for α and β .

(b) Using your MMEs above as the initial values for optim, derive the MLE for α and β .

(2) We propose a lifetime model with the following mortality intensity function: µ(t) = α × λα  × tα 1 ,    t ≥ 0.

(a) Derive algebraically the probability density function for lifetime and write down

the joint-likelihood of the given sample.

(b) Using the optim method in R, numerically obtain the maximum likelihood esti- mators of the model parameters.4

Question 3. Cancer patients who are in remission are observed and the number of days until the symptoms reappear is recorded.5  Some records have been right-censored. The data set is provided in a spreadsheet named cancer.xlsx and the columns therein are:

• time: the time until reappearance of symptoms in number of days.

• event: an indicator variable taking value 0 if the record has been right-censored and

1 if fully observed.

• fullyObserved: logical variable indicating whether the record has been fully observed.

• sex: categorical variable with value 0 for male (the reference group) and 1 for female.

(1) Calculate the Kaplan-Meier estimate for survival probabilities.

(2) Using the Greenwood’s formula:

Var( (t)) ( (t))2   ,t [t(k),t(k+1)),

calculate the variance of (t) at the fully observed times t(i),i = 1, 2, ....

Question 4. In this question, we will fit a Cox Proportional Hazard model on the same data set in Question 3, with time as the response variable and sex as the categorical covariate.

(1) By using the survival package or otherwise, calculate the MLE for the Cox Propor- tional Hazard Model.

(2) Based on the output you have generated, perform the z-test, Score test, and Likeli- hood Ratio test on the following hypotheses:

H0  : β = 0,    vs   H1  : β  0.