Estimates the marginal effects of an exposure while accounting for expected changes in co-occurring exposures at the same time point. Values of co-occurring exposures are modeled nonlinearly using a spline model with predictions made at the lower an upper values for the exposure of interest.
adj_coexposure(
exposure.data,
object,
contrast_perc = c(0.25, 0.75),
contrast_exp = list(),
conf.level = 0.95,
keep.mcmc = FALSE,
verbose = TRUE
)A list with the following components (or posterior samples if keep.mcmc = TRUE):
vector of exposure names
integer vector of lags
posterior mean of marginal effects
standard error of the estimate
lower bound of credible interval of the marginal effect estimate
upper bound of credible interval of the marginal effect estimate
cumulative marginal effects
lower bound of credible interval of the cumulative marginal effect
upper bound of credible interval of the cumulative marginal effect
boolean vector indicating critical window
Named list of exposure matrices used as input to TDLMM.
Model output for TDLMM from dlmtree() function.
2-length vector of percentiles or named list corresponding to lower and upper exposure percentiles of interest. Names must equal list names in 'exposure.data'.
Named list consisting lower and upper exposure values. This takes precedence over contrast_perc if both inputs are used.
Confidence level used for estimating credible intervals. Default is 0.95.
If TRUE, return posterior samples.
TRUE (default) or FALSE: print output
adj_coexposure