How to fit an animal model

An ecologist guide

Tutorial on how to fit an animal model using multiple R packages. Updated and extended tutorials from An ecologist guide to animal model (Wilson et al. 2010).


Julien Martin

Mathieu Videlier





This book is a collection of tutorial from the excellent paper by (Wilson et al. 2010). The tutorials have been updated to work with the latest version of the softwares, extended with extra information and other softwares have been added. Eric Postma kindly provided an updated version of the original asreml-r tutorial from asreml-r v3 to asreml-r v4.

This is a living document and information is updated/added regularly

Citing the book

Julien Martin & Mathieu Videlier (2024). How to fit an Animal model? A guide for evolutionary ecologist using multiple R packages. Version: 1.0.0 (2024-04-24).


We provide this book under the license Creative Commons Attribution-NonCommercial-ShareAlike 4.0 International.

Feel free to use some or all of the content in this book. The only thing we ask is that you acknowledge the original source and authors as per the license and use the same license if you share that work publicly. If you find this book useful or have any comments or suggestions we would love to hear from you (contact info).

Image credit

The cover image was generated by Julien Martin using the Nightcafe AI image generator using the call “Family tree of legendary beast”.

Who are we ?


Julien Martin is a Professor at the University of Ottawa working on Evolutionary Ecology and has discovered R with version 1.8.1 and teaches R since v2.4.0. He developed the first version of the book in February 2021 and now continues to develop the book and maintains the site for all languages (currently only english but french and spanish comin soon).


Mathieu Videlier is currently a postdoctoral fellow collaborating with Pr. Jacqueline Sztepanacz at University of Toronto. In joined the project in May 2021 . He added and continues to add more details in the document. He is also spearing the translation fo French and Spanish.

Hex Sticker