dlim-package | R Documentation |
The package dlim contains functions to fit, perform inference and estimation on, and visualize a distributed lag interaction model (DLIM).
A distributed lag interaction model (DLIM) is an extension of a distributed lag model. A DLIM regresses an outcome onto repeated measures of an exposure and allows for associations to vary by a single continuous modifier. More details on methodology are provided in the reference listed below.
To fit a DLIM using this package, use the dlim
function, which calls the cross_basis
function to create the cross-basis and estimates regression coefficients using gam
from mgcv package.
The predict.dlim
S3 function provides point-wise or cumulative effect estimates and uncertainty measures.
The plot_DLF
and plot_cumulative
functions provide plots of the modified distributed lag functions and the cumulative effect estimate curve.
Additonal details on the package dlim are available in the vignette, available by typing:
vignette("dlimOverview")
The dlim package is available on the Comprehensive R Archive Network (CRAN). A development website is available on GitHub (github.com/ddemateis/dlim).
Please use citation("dlim")
to cite this package.
Danielle Demateis, Kayleigh Keller, and Ander Wilson
Maintainer: Danielle Demateis <Danielle.Demateis@colostate.edu>
Demateis et al. (2024) <doi:10.1002/env.2843>, avaibable at (arxiv.org/abs/2401.02939).
Type 'vignette(dlimOverview)'
for a detailed description.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.