Solutions: https://www.paulamoraga.com/course-aramco/99-problems-5glm-solutions.html

1 GLMs

1.1 GLMs Poisson

Whyte, et al 1987 (Dobson, 1990) reported the number of deaths due to AIDS in Australia per 3 month period from January 1983 to June 1986. The data are explanatory variable \(X\): time (measured in multiple of 3 month after January 1983), and response variable \(Y\): number of deaths in Australia due to AIDS.

x <- 1:14
y <- c(0, 1, 2, 3, 1, 4, 9, 18, 23, 31, 20, 25, 37, 45)
cbind(x, y)
##        x  y
##  [1,]  1  0
##  [2,]  2  1
##  [3,]  3  2
##  [4,]  4  3
##  [5,]  5  1
##  [6,]  6  4
##  [7,]  7  9
##  [8,]  8 18
##  [9,]  9 23
## [10,] 10 31
## [11,] 11 20
## [12,] 12 25
## [13,] 13 37
## [14,] 14 45
  • Fit a Poisson regression model using time as explanatory variable
  • Interpret the coefficient estimate of time
  • Test if time has an effect on the number of death due to AIDS

1.2 GLMs Binomial

The following R output reports the result of an experiment for pesticide which attempted to kill beetles. Beetles were exposed to gaseous carbon disulphide at various concentrations (in mg/L) for five hours and the number of beetles killed were noted.

Call:
glm(formula = cbind(Killed, Survived) ~ Dose, family = binomial)
> summary(modl)
Coefficients:
             Estimate  Std. Error  z value  Pr(>|z|)
(Intercept) -14.82300     1.28959   -11.49    <2e-16 ***
Dose          0.24942     0.02139    11.66    <2e-16 ***
Null deviance:   284.2024 on 7 degrees of freedom
Residual deviance: 7.3849 on 6 degrees of freedom
> vcov(modl)
             (Intercept)          Dose
(Intercept)   1.66302995 -0.0274363845
Dose         -0.02743638  0.0004573762
  • Write down the fitted model.
  • Perform a hypothesis test to determine the significance of Dose. You need to state the hypothesis, state the calculated test statistic, state the reference distribution under the null hypothesis, set a decision rule and state the conclusion.
  • Estimate the odds ratio as well as its significance when Dose increases 4 units. Interpret the odds ratio.
  • Provide the 95% confidence interval for the probability of killing when the value of Dose equals 62.