Skip to content

Fix weight propagation and trimming logic#72

Merged
alexanderquispe merged 6 commits intod2cml-ai:mainfrom
gsaco:main-copy1
Jan 12, 2026
Merged

Fix weight propagation and trimming logic#72
alexanderquispe merged 6 commits intod2cml-ai:mainfrom
gsaco:main-copy1

Conversation

@gsaco
Copy link
Collaborator

@gsaco gsaco commented Jan 11, 2026

Report.pdf

I corrected five identified bugs. As a result, the Python package now produces outputs that exactly match those of the reference R and Stata implementations.

Bugs Fixed:

Bug 1. Weight Propagation Failure: User-specified weights were silently ignored in the esti-
mation pipeline.
Bug 2. Panel Data Misrouting: Unbalanced panel data was incorrectly routed to repeated
cross-section (RCS) estimators.
Bug 3. Universal Base Period Logic Error: Time index was compared against year values,
causing influence function shape mismatches.
Bug 4. MissingPropensityScoreTrimming: DRDID-defaulttrimming(trim_level=0.995)
was not applied to IPW/DR estimators.
Bug 5. Scalar Aggregation Crash: Single-group aggregations failed due to scalar vs. array
handling.

@alexanderquispe
Copy link
Contributor

great! this is related to #72 #67

@alexanderquispe alexanderquispe merged commit 3d95090 into d2cml-ai:main Jan 12, 2026
1 check failed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants