Illustration of conditional Poisson models as an alternative method in analyses of environmental data. In particular, this represents a computationally convenient alternative to both conditional logistic case-crossover models (when data are aggregated in time series form) and to standard Poisson regression for long time series (when control for time is achieved with computationally expensive spline functions). The code follows the examples included in this article that illustrates the methodology and some applications:
Armstrong B, Gasparrini A, Tobias A. Conditional Poisson models: a flexible alternative to conditional logistic case cross-over analysis. BMC Medical Research Methodology. 2014;14(1):122.. [freely available here]
The material:
- londondataset2002_2006.csv stores the dataset used in the illustrative examples
- funccmake.R generates the R function to convert data from time series to case-crossover formats
- Rcode.R is the R code to reproduce the examples
- Statacode.do is the Stata code to reproduce the examples
Download as a ZIP file using the green button Clone or download above