Beginner's Guide to

Spatial, Temporal and Spatial-Temporal Ecological Data Analysis with R-INLA (2017)

Zuur, Ieno, Saveliev

This book consists of two volumes. You are viewing the webpage for Volume I, Using GLM and GLMM. Volume II is entitled Using GAM and Zero-Inflated Models, and will be available towards the end of 2018.

Volume I: Table of Contents

Volume I: Pdf of Chapter 1

 

Volume I

In Volume I we explain how to apply linear regression models, generalised linear models (GLM), and generalised linear mixed-effects models (GLMM) to spatial, temporal, and spatial-temporal data. The models that will be employed use the Gaussian and gamma distributions for continuous data, the Poisson and negative binomial distributions for count data, the Bernoulli distribution for absence–presence data, and the binomial distribution for proportional data.

 

Click here to order Volume I (or click on the 'Order Books or E-Books' at the top on the left-menu)

 

Volume II

In Volume II we apply zero-inflated models and generalised additive (mixed-effects) models to spatial and spatial-temporal data. We also discuss models with more exotic distributions like the generalised Poisson distribution to deal with underdispersion and the beta distribution to analyse proportional data.

 

Outline of Volume I

In Chapter 2 we discuss an important topic: dependency. Ignoring this means that we have pseudoreplication. We present a series of examples and discuss how dependency can manifest itself.

We briefly discuss frequentist tools that are available for the analysis of temporal and spatial data in Chapters 3 and 4, and we will conclude that their application is rather limited, especially if non-Gaussian distributions are required. We will therefore consider alternative models, but these require Bayesian techniques.

In Chapter 5 we discuss linear mixed-effects models to analyse hierarchical (i.e. clustered or nested) data, and in Chapter 6 we outline how we add spatial and spatial-temporal dependency to regression models via spatial (and/or temporal) correlated random effects.

In Chapter 7 we introduce Bayesian analysis, Markov chain Monte Carlo techniques (MCMC), and Integrated Nested Laplace Approximation (INLA). INLA allows us to apply models to spatial, temporal, or spatial-temporal data.

In Chapters 8 through 16 we present a series of INLA examples. We start by applying linear regression and mixed-effects models in INLA (Chapters 8 and 9), followed by GLM examples in Chapter 10. In Chapters 11 through 13 we show how to apply GLM models on spatial data. In Chapter 14 we discuss time-series techniques and how to implement them in INLA. Finally, in Chapters 15 and 16 we analyse spatial-temporal models in INLA.

 

Data and R code

All data is freely available. All the R code is provided as well, except that a password is needed to open the zip files. The password is given in the Preface of the book (see page vi). In some chapters we are sourcing our support file HighstatLibV10.R.

 

Below you can add comments for this book. For questions, please use the Discussion board (see link in the menu).

 

 

 

 

 

Comments (19)

Rated 0 out of 5 based on 0 votes
  1. Alain Zuur

This is a short message from one of the authors of this book; Alain Zuur.

We teach around 25 statistics courses per year, all over the world. For years, participants have been asking for courses on spatial, temporal and spatial-temporal GLMs....

This is a short message from one of the authors of this book; Alain Zuur.

We teach around 25 statistics courses per year, all over the world. For years, participants have been asking for courses on spatial, temporal and spatial-temporal GLMs. It was only when R-INLA became available that we started to add such a module to our courses. A single module became two modules, two modules became a 5-day course....and eventually we wrote this book in 2016.

R-INLA allows the user to apply sophisticated models, but the underlying theory is rather daunting (unless you like integrals). The aim of this book is to make the R-INLA world understandable for a non-technical audience. We hope that we succeeded.

We do get the occasional email complaining about the price of the book. We agree that this is not a cheap book. But what is 89 GBP compared to 3 years of field work? Sometimes you are lucky when you buy a book in the sense that everything you need for the analysis of your own data is in it. We think that this is such a book.

One of the chapters in the book is about storks. They say that storks bring babies. Well...when we wrote the storks chapter in October 2016, my wife found out that she was pregnant from a twin. On 5 June 2017, Aidan and Naila were born. Babies and mother are doing well. Father is doing well too...and has become an expert in nappy changing.

So...storks do bring babies!

Alain

Read More
  Attachments
 
  1. Marc Girondot

When the book will be fully available ?
The link http://www.highstat.com/Data/White_Stork_Growth_20112012_V2.csv is not valid.
Thanks to put this online.

  Attachments
 
  1. Alain Zuur    Marc Girondot

Marc..thanks. I have updated the link to the white stork data. It is:

http://highstat.com/Books/BGS/SpatialTemp/Data/White_Stork_Growth_20112012_V2.csv

The book is fully available....but I guess your question is when all the R code is...

Marc..thanks. I have updated the link to the white stork data. It is:

http://highstat.com/Books/BGS/SpatialTemp/Data/White_Stork_Growth_20112012_V2.csv

The book is fully available....but I guess your question is when all the R code is available? I got sidetracked with the first chapter of Volume II (a chapter on zero inflated and spatial correlated models in INLA)..but I will try to upload all the R code of Volume I this week.

Kind regards,
Alain

Read More
  Attachments
 
  1. Alain Zuur    Alain Zuur

Friday 14 July 2017: All data sets and all R code has now been uploaded. Please send me an email (highstat@highstat.com) in case a link doesn't work, or if a piece of R does not run.

Alain

  Attachments
 
  1. Alex

Where can I buy the book?

  Attachments
 
  1. Alain Zuur    Alex

At the top left of this page you will see a menu...and the first menu item states: "Order books or E-books". If you click on it, then you will be transferred to:

http://highstat.com/index.php/order-books-or-e-books

This book can only be bought...

At the top left of this page you will see a menu...and the first menu item states: "Order books or E-books". If you click on it, then you will be transferred to:

http://highstat.com/index.php/order-books-or-e-books

This book can only be bought from this link. I will add a credit card logo so that it is more clear.


Kind regards,

Alain

Read More
  Attachments
 
  1. Alain Zuur    Alain Zuur

I have added a VISA/Mastercard pic to make more clear where the book can be bought.

Kind regards,
Alain

  Attachments
 
  1. John T. Finn

I have had problems with the .txt files in Chapters 14 and 15. They come in as only a single record (no carriage returns). I have a Windows computer. The .csv files in Chapter 14 worked fine. Thanks.

  Attachments
 
  1. Alain Zuur    John T. Finn

John...thanks for the comment. I guess going from a Mac OS, to an internet file, and then to your Windows computer has caused some trouble. I have zipped the original files and uploaded these. Please let me know if this does not solve the...

John...thanks for the comment. I guess going from a Mac OS, to an internet file, and then to your Windows computer has caused some trouble. I have zipped the original files and uploaded these. Please let me know if this does not solve the problem.

Kind regards,
Alain

Read More
  Attachments
 
  1. Daniel Câmara

Hi, even though the book and chapters names mention only inla, I'd like to know if the examples are also implemented in jags. Many thanks for your incredible work me. Zuur!

  Attachments
 
  1. Alain Zuur    Daniel Câmara

Dear Daniel,

Doing models with spatial correlation in JAGS is a major challenge.... You could try WinBUGS. But the whole point of INLA is to avoid MCMC. I managed to burn a Macbook while running spatial models in WinBUGS.

We did write a book...

Dear Daniel,

Doing models with spatial correlation in JAGS is a major challenge.... You could try WinBUGS. But the whole point of INLA is to avoid MCMC. I managed to burn a Macbook while running spatial models in WinBUGS.

We did write a book containing lots of JAGS code for GLMs, GLMMs, zero inflated models, beta models, etc. That is this one:

http://highstat.com/index.php/beginner-s-guide-to-zero-inflated-models

But there is no spatial correlation in the zero inflarion book; just JAGS. You could try OpenBUGS for that.
Good to hear you like our books.

Kind regards,
Alain

Read More
  Attachments
  Comment was last edited about 4 months ago by Super User Super User
  1. Daniel Câmara    Alain Zuur

Thanks for your answer mr. Zuur. In fact I didn't know about this problem with spatial correlation in jags. Thanks for explaining this. In fact I use bugs, but I'm not that proficient with it yet. I've had contact with inla some time ago and was...

Thanks for your answer mr. Zuur. In fact I didn't know about this problem with spatial correlation in jags. Thanks for explaining this. In fact I use bugs, but I'm not that proficient with it yet. I've had contact with inla some time ago and was very impressed with its power. I'll be sending an email to you to ask some more questions before I buy this book (which I'm very excited about). Thanks again for your time and kindness!

Read More
  Attachments
 
  1. MB

I can't seem to find the file HighstatLibV10.R mentioned in chapter 2. Can you please point to where it is.

  Attachments
 
  1. Alain Zuur    MB

Sorry..I forgot that we used it. I have uploaded the file and adjusted the text above. You may need to refresh your browser in order to see it.

Note that you need to Right-Mouse click on the link, and select 'Save Link As'. Otherwise it...

Sorry..I forgot that we used it. I have uploaded the file and adjusted the text above. You may need to refresh your browser in order to see it.

Note that you need to Right-Mouse click on the link, and select 'Save Link As'. Otherwise it becomes a *.R.html file, and then you cannot source it.

Alain

Read More
  Attachments
 
  1. Marcello DE GIOSA

Alain,
it seems to me something is wrong with file LaPalma.txt on ch13.
I'm not able to correctly read the file in R. By direct inspection it seems something is lost in the file.
Please, may you check it.

Regards

MDG

Warning message:
In...

Alain,
it seems to me something is wrong with file LaPalma.txt on ch13.
I'm not able to correctly read the file in R. By direct inspection it seems something is lost in the file.
Please, may you check it.

Regards

MDG

Warning message:
In read.table(file = "LaPalma.txt", header = TRUE, dec = ".") :
incomplete final line found by readTableHeader on 'LaPalma.txt'

Read More
  Attachments
 
  1. Alain Zuur    Marcello DE GIOSA

Marcello,
Apologies for the delay in responding; nappy changing duties.
I have uploaded the file again using a different ftp program. I think/hope that it is ok now. Otherwise, I will upload it as an Excel file.

Kind regards,
Alain

  Attachments
 

Could we get the data for chapter 10? something is wrong with most of those files
thanks

  Attachments
 
  1. Alain Zuur   

Fixed.

Alain

  Attachments
 
  1. Gustavo Machado    Alain Zuur

Thank you very much

  Attachments
 
There are no comments posted here yet

Leave your comments

Posting comment as a guest.
Attachments (0 / 3)
Share Your Location