Commit 187cd21
fix(lpdid): non-absorbing pooled-pre uses deepest reach-back horizon
Codex P1: `_build_pooled_sample(kind="pre")` passed horizon=0 to the
non-absorbing masks, so the effect_stabilization clean window only covered
[t-L, t] instead of the pooled-pre reach-back to the most-negative horizon
([t - max(L, -h), t-1]). A unit with a prior treated spell at t-3 (clean at
t-1) leaked into a [-3, -2] pooled-pre placebo and biased it. Pre windows now
use min(horizons); the absorbing branch keeps horizon=0 (not-yet-treated at t
already implies a clean pre-span, so its R-parity goldens are unchanged).
Adds a deterministic regression test (spell entrants excluded from the
pooled-pre sample; verified to fail at 0.286 before the fix).
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>1 parent 90af194 commit 187cd21
2 files changed
Lines changed: 29 additions & 1 deletion
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
962 | 962 | | |
963 | 963 | | |
964 | 964 | | |
965 | | - | |
| 965 | + | |
| 966 | + | |
| 967 | + | |
| 968 | + | |
| 969 | + | |
| 970 | + | |
| 971 | + | |
966 | 972 | | |
967 | 973 | | |
968 | 974 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1621 | 1621 | | |
1622 | 1622 | | |
1623 | 1623 | | |
| 1624 | + | |
| 1625 | + | |
| 1626 | + | |
| 1627 | + | |
| 1628 | + | |
| 1629 | + | |
| 1630 | + | |
| 1631 | + | |
| 1632 | + | |
| 1633 | + | |
| 1634 | + | |
| 1635 | + | |
| 1636 | + | |
| 1637 | + | |
| 1638 | + | |
| 1639 | + | |
| 1640 | + | |
| 1641 | + | |
| 1642 | + | |
| 1643 | + | |
| 1644 | + | |
| 1645 | + | |
1624 | 1646 | | |
1625 | 1647 | | |
1626 | 1648 | | |
| |||
0 commit comments