Chapter 1 Learning objectives

The goal of Workhsop 8 is to first examine what we mean by a non-linear model, and how Generalized Additive Models (GAMs) allow us to handle non-linear relationships. We will also go over how to plot and interpret these non-linear relationships, how to include interaction terms, autocorrelated errors, and expand on previous workshops by briefly examining a mixed modelling framework. Lastly, we will briefly touch upon what GAMs are doing behind the scenes.

We recommend some working experience in R, particularly with examining data and objects in R scripts, and a basic knowledge of linear regression before following this workshop.

More specifically, this workshop will cover how to:

  1. Use the mgcv package to fit non-linear relationships,
  2. Understand the output of a GAM to help you understand your data,
  3. Use tests to determine if a non-linear model fits better than a linear one,
  4. Include smooth interactions between variables,
  5. Understand the idea of a basis function, and why it makes GAMs so powerful,
  6. Account for dependence in data (autocorrelation, hierarchical structure) using GAMMs.