Fixing the mediator distribution at the reference arm rather than at each person own counterfactual value is what makes this identified when an exposure-induced confounder sits between mediator and outcome. The mediator model is fitted on the reference arm and imposed on all.
Examples
Tmlnde2(y = c(1, 2, 3, 4, 5, 6, 7, 8), D = 5L, M = 5L, X = c(1, 2, 3, 4, 5, 6, 7, 8))
#> $estimate
#> [1] 4.563542e+30
#>
#> $se
#> [1] 0
#>
#> $eps
#> [1] 1.090934e+14
#>
#> $m_shift
#> [1] -5
#>
#> $n
#> [1] 8
#>
#> $method
#> [1] "TMLE for an interventional direct effect"
#>
#> attr(,"class")
#> [1] "morie_rich_result" "list"
