Count data: To Log or Not To Log

Count data are widely collected in ecology, for example when one count the number of birds or the number of flowers. These data follow naturally a Poisson or negative binomial distribution and are therefore sometime tricky to fit with standard LMs. A traditional approach has been to log-transform such data and then fit LMs to … Continue reading Count data: To Log or Not To Log

Checking (G)LM model assumptions in R

(Generalized) Linear models make some strong assumptions concerning the data structure: Independance of each data points Correct distribution of the residuals Correct specification of the variance structure Linear relationship between the response and the linear predictor For simple lm 2-4) means that the residuals should be normally distributed, the variance should be homogenous across the … Continue reading Checking (G)LM model assumptions in R

Generalized Linear Modelling in R (part 1)

In classical linear modelling we are assuming that the response variable (Y) is normally distributed, however for certain type of data like count data or presence/absence data this is not the case. There is in statistic an ensemble of technique called Generalized Linear Modelling (GLM in short) where the reponse variable follow one known distribution, … Continue reading Generalized Linear Modelling in R (part 1)