  Traditional mediation analysis typically examines the relations among an
intervention, a time-invariant mediator, and a time-invariant outcome variable.
Although there may be a direct effect of the intervention on the outcome, there
is a need to understand the process by which the intervention affects the
outcome (i.e. the indirect effect through the mediator). This indirect effect
is frequently assumed to be time-invariant. With improvements in data
collection technology, it is possible to obtain repeated assessments over time
resulting in intensive longitudinal data. This calls for an extension of
traditional mediation analysis to incorporate time-varying variables as well as
time-varying effects. In this paper, we focus on estimation and inference for
the time-varying mediation model, which allows mediation effects to vary as a
function of time. We propose a two-step approach to estimate the time-varying
mediation effect. Moreover, we use a simulation based approach to derive the
corresponding point-wise confidence band for the time-varying mediation effect.
Simulation studies show that the proposed procedures perform well when
comparing the confidence band and the true underlying model. We further apply
the proposed model and the statistical inference procedure to real-world data
collected from a smoking cessation study.
