Skip to main content
. Author manuscript; available in PMC: 2026 Jul 15.
Published in final edited form as: Ann Stat. 2025 Feb 13;53(1):400–425. doi: 10.1214/24-aos2475

Algorithm 2.

Estimation for the infinite-horizon setting

Input: Observed data Ait,Mit,Rit:i=1,,n,t=1,,T, the number of bootstrap samples B, and the significance level α.
Output: Estimated individual mediation effect η^j(), for j=1,,d.
1: Pool data across all t stages, t=1,,T.
2: Estimate parameters W^,𝚯^1,𝚯^2 using the pooled data.
3: Estimate θM1jM1 and θM1jR1 using the pooled data.
4: Compute B1 to B7 using (25).
5: Compute η^j() using (24).
6: for b=1,,B do
7:  Sample n trajectories from the observed data with replacement.
8:  Repeat Lines 1 to 5 to compute ηˆj(,b) using the bootstrap samples.
9: end for
10: Construct the CI η^j(,L),η^j(,U) for ηj(), where η^j(,L) and η^j(,U) are the empirical lower and upper α/2 quantiles of η^j(,b)b=1B, respectively.