You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Resolve merge conflict, match R colMeans convention in panel IPW/DR M2 gradients
Resolve TODO.md merge conflict (keep our resolved items from Phase 7).
Panel IPW/DR PS nuisance gradients (M2, M2_dr): change np.mean() over
control rows to np.sum() / (n_t + n_c), matching R's colMeans() over
ALL n observations (zero for treated). This makes the panel paths
consistent with the RC paths' R-convention refactoring.
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Copy file name to clipboardExpand all lines: CHANGELOG.md
+29Lines changed: 29 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -7,6 +7,34 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
7
7
8
8
## [Unreleased]
9
9
10
+
## [2.7.6] - 2026-03-28
11
+
12
+
### Added
13
+
-**AI practitioner guardrails** based on Baker et al. (2025) "Difference-in-Differences Designs: A Practitioner's Guide"
14
+
-`practitioner.py` module with 8-step workflow enforcement for AI agents
15
+
- Estimator-specific handlers ensuring correct diagnostic ordering (pre-trends before estimation, Bacon decomposition before estimator selection)
16
+
-`docs/llms.txt`, `docs/llms-practitioner.txt`, `docs/llms-full.txt` for AI agent discoverability
17
+
- Evaluation rubric (`docs/practitioner-guide-evaluation.md`) with correctness-aware scoring
18
+
-**Survey Phase 6: Advanced features**
19
+
- Survey-aware bootstrap for all 8 bootstrap-using estimators (PSU-level multiplier for CS/Imputation/TwoStage/Continuous/Efficient; Rao-Wu rescaled for SA/SyntheticDiD/TROP)
20
+
- Replicate weight variance estimation (BRR, Fay's BRR, JK1, JKn) for OLS-based and IF-based estimators
21
+
- Per-coefficient DEFF diagnostics comparing survey vs SRS variance
22
+
- Subpopulation analysis via `SurveyDesign.subpopulation()` preserving full design structure
23
+
- CS analytical expansion: strata/PSU/FPC for aggregated SEs via `compute_survey_if_variance()`
24
+
- TROP cross-classified pseudo-strata for survey-aware bootstrap
25
+
26
+
### Changed
27
+
- Estimator-specific guidance for parallel trends tests and placebo checks (no shared templates)
28
+
- SDiD and TROP split into separate decision tree branches in practitioner workflow
29
+
30
+
### Fixed
31
+
- Fix replicate weight df calculation using pivoted QR rank with R-compatible tolerance
32
+
- Fix replicate IF variance score scaling for EfficientDiD, TripleDiff, ContinuousDiD
33
+
- Fix panel-to-unit replicate weight propagation and normalization
34
+
- Fix CS zero-mass return type and vectorized guard for survey paths
35
+
- Fix `solve_logit` effective-sample validation for zero-weight designs
36
+
- Fix subpopulation mask validation and EfficientDiD bootstrap guard
37
+
10
38
## [2.7.5] - 2026-03-23
11
39
12
40
### Added
@@ -978,6 +1006,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
978
1006
-`to_dict()` and `to_dataframe()` export methods
979
1007
-`is_significant` and `significance_stars` properties
If you are an AI agent or LLM using this library, read [`docs/llms.txt`](docs/llms.txt) for a concise API reference with an 8-step practitioner workflow (based on Baker et al. 2025). The workflow ensures rigorous DiD analysis — not just calling `fit()`, but testing assumptions, running sensitivity analysis, and checking robustness.
73
+
74
+
After estimation, call `practitioner_next_steps(results)` for context-aware guidance on remaining diagnostic steps.
|`visualization/`| 4172 | Subpackage (split across 7 files) — OK |
41
44
42
45
---
43
46
@@ -49,8 +52,7 @@ Deferred items from PR reviews that were not addressed before merge.
49
52
50
53
| Issue | Location | PR | Priority |
51
54
|-------|----------|----|----------|
52
-
| ImputationDiD dense `(A0'A0).toarray()` scales O((U+T+K)^2), OOM risk on large panels |`imputation.py`|#141| Medium (deferred — only triggers when sparse solver fails; fixing requires sparse least-squares alternatives) |
53
-
| EfficientDiD: API docs / tutorial page for new public estimator |`docs/`|#192| Medium |
55
+
| ImputationDiD dense `(A0'A0).toarray()` scales O((U+T+K)^2), OOM risk on large panels |`imputation.py`|#141| Medium (deferred — only triggers when sparse solver fails) |
54
56
| Multi-absorb weighted demeaning needs iterative alternating projections for N > 1 absorbed FE with survey weights; unweighted multi-absorb also uses single-pass (pre-existing, exact only for balanced panels) |`estimators.py`|#218| Medium |
55
57
| Replicate-weight survey df — **Resolved**. `df_survey = rank(replicate_weights) - 1` matching R's `survey::degf()`. For IF paths, `n_valid - 1` when dropped replicates reduce effective count. |`survey.py`|#238| Resolved |
@@ -75,11 +77,11 @@ Deferred items from PR reviews that were not addressed before merge.
75
77
76
78
| Issue | Location | PR | Priority |
77
79
|-------|----------|----|----------|
80
+
| Plotly renderers silently ignore styling kwargs (marker, markersize, linewidth, capsize, ci_linewidth) that the matplotlib backend honors; thread them through or reject when `backend="plotly"`|`visualization/_event_study.py`, `_diagnostic.py`, `_power.py`|#222| Medium |
78
81
| R comparison tests spawn separate `Rscript` per test (slow CI) |`tests/test_methodology_twfe.py:294`|#139| Low |
79
82
| CS R helpers hard-code `xformla = ~ 1`; no covariate-adjusted R benchmark for IRLS path |`tests/test_methodology_callaway.py`|#202| Low |
80
-
|~376 `duplicate object description` Sphinx warnings — caused by autodoc `:members:` on dataclass attributes within manual API pages (not from autosummary stubs); fix requires restructuring `docs/api/*.rst` pages to avoid documenting the same attribute via both `:members:` and inline `autosummary` tables |`docs/api/*.rst`| — | Low |
81
-
| Plotly renderers silently ignore styling kwargs (marker, markersize, linewidth, capsize, ci_linewidth) that the matplotlib backend honors; thread them through or reject when `backend="plotly"`|`visualization/_event_study.py`, `_diagnostic.py`, `_power.py`|#222| Medium |
82
-
| Survey bootstrap test coverage — **Resolved**. Added FPC census zero-variance, single-PSU NaN, full-design bootstrap for CS/ContinuousDiD/EfficientDiD, and TROP Rao-Wu vs block bootstrap equivalence tests. |`tests/test_survey_phase*.py`| — | Resolved |
0 commit comments