Published in

PeerJ, PeerJ, (7), p. e6876, 2019

DOI: 10.7717/peerj.6876

Links

Tools

Export citation

Search in Google Scholar

Hierarchical generalized additive models in ecology: an introduction with mgcv

Journal article published in 2019 by Eric J. Pedersen ORCID, David L. Miller ORCID, Gavin L. Simpson ORCID, Noam Ross ORCID
This paper is made freely available by the publisher.
This paper is made freely available by the publisher.

Full text: Download

Red circle
Preprint: archiving forbidden
Red circle
Postprint: archiving forbidden
Green circle
Published version: archiving allowed
Data provided by SHERPA/RoMEO

Abstract

In this paper, we discuss an extension to two popular approaches to modeling complex structures in ecological data: the generalized additive model (GAM) and the hierarchical model (HGLM). The hierarchical GAM (HGAM), allows modeling of nonlinear functional relationships between covariates and outcomes where the shape of the function itself varies between different grouping levels. We describe the theoretical connection between HGAMs, HGLMs, and GAMs, explain how to model different assumptions about the degree of intergroup variability in functional response, and show how HGAMs can be readily fitted using existing GAM software, themgcvpackage in R. We also discuss computational and statistical issues with fitting these models, and demonstrate how to fit HGAMs on example data. All code and data used to generate this paper are available at:github.com/eric-pedersen/mixed-effect-gams.