To download the solutions for each of the exercises as individual R scripts click the relevant links below. If the code opens in a browser window then right click on the link and select ‘save link as’ (or similar).
Exercise 1 solutions
Exercise 2 solutions
Exercise 3 solutions
Exercise 4 solutions
Exercise 5 solutions
Graphical data exploration exercise
Linear model with single continuous explanatory variable exercise
Linear model with single categorical explanatory variable exercise
Linear model with multiple explanatory variables exercise
Linear model - model selection exercise
Generalised linear models 1 - Poisson GLM exercise
Generalised linear models 2 - Binomial GLM exercise