Worthington, Thomas A
2013-Aug-06 13:55 UTC
[R] Temporal Correlation in Logistic Regression
I am attempting to create a logistic regression model to examine the factors that determine the emergence of four species of aquatic invertebrates. The invertebrates were trapped at two sites over a period of two years. The traps were emptied on an irregular spaced basis (with an extended gap over the winter period) and both sites were not always visited on the same day. I have two covariates I would like to test, discharge which is the same at both sites and temperature with is different between the sites. The main aim of the analysis is to see whether the difference temperature regimes between the two sites alters the probability the invertebrates will emerge. I had planned to test the this using a GLM of the form model1<-glm(B.rhodani_Pres ~ Temp+ Discharge + Temp:Site_Code, family = binomial()) However examination of the Durbin Watson statistic suggests the residuals for the four models (one for each species) are highly autocorrelated. Does anyone have any ideas how I can incorporate the temporal autocorrelation into the models? Any advice would be greatly appreciated Tom [[alternative HTML version deleted]]