A tutorial illustrating the use of the R package dlnm in time series analysis. The package implements distributed lag linear and non-linear models in R. The code illustrates the capabilities of the package, reproducing the examples in the article:
Gasparrini A. Distributed lag linear and non-linear models in R: the package dlnm. Journal of Statistical Software. 2011;43(8):1-20. DOI: 10.18637/jss.v043.i08. PMID: 22003319. [freely available here]
Note: the original R code accompanying the article refers to an old version of the R package with an outdated syntax. The code has been updated here.
The code:
- Rcode.R contains the R code for reproducing the examples in the article
Download as a ZIP file using the green button Clone or download above