Skip to content
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
wooldridge: CI R5 P3 fixes — narrow panel CSV columns + cohort_trend_…
…coefs baseline-normalization docstring
  • Loading branch information
igerber committed May 23, 2026
commit 200975d3d753ba138c44bf4d2724be2eab5bfc13
8 changes: 6 additions & 2 deletions benchmarks/R/generate_wooldridge_golden.R
Original file line number Diff line number Diff line change
Expand Up @@ -288,8 +288,12 @@ df$y_pois <- rpois(nrow(df), lambda = exp(0.5 + 0.3 * D))
# Logit outcome: p = plogis(0.0 + 0.8 * D)
df$y_logit <- rbinom(nrow(df), size = 1L, prob = plogis(0.0 + 0.8 * D))

# Save augmented panel back so Python loads the same outcomes.
write.csv(df, panel_path, row.names = FALSE)
# Save augmented panel back so Python loads the same outcomes. Subset to
# the canonical fixture columns + new nonlinear outcomes to avoid
# polluting the panel CSV with the OLS-stage `D_g_t` working columns
# (codex CI R5 P3 fix — keeps the benchmark input contract narrow).
panel_columns <- c("unit", "time", "cohort", "y", "y_pois", "y_logit")
write.csv(df[, panel_columns], panel_path, row.names = FALSE)
cat(sprintf("Wrote augmented panel with y_pois + y_logit to %s\n", panel_path))

# Fit etwfe(family="poisson")
Expand Down
18 changes: 9 additions & 9 deletions benchmarks/data/wooldridge_golden.json
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@
"sandwich_version": "3.1.1"
},
"point_estimates": {
"interaction_coefs": [0.76614176414719071, 0.88267316960019337, 1.1986682582624895, 1.4873820142516874, 0.39177980252905253, 0.63325934470689971],
"interaction_coefs": [0.76614176414718926, 0.88267316960019226, 1.1986682582624884, 1.4873820142516871, 0.39177980252905398, 0.63325934470689782],
"gt_keys": [
{
"g": 3,
Expand Down Expand Up @@ -67,13 +67,13 @@
]
},
"hc1": {
"per_coef_se": [0.06096060031056097, 0.059046218350942571, 0.069811491900727871, 0.064215951133206925, 0.064370685282068074, 0.081348726856405193],
"overall_att_se": 0.035044276020269757
"per_coef_se": [0.060960600310560775, 0.059046218350942425, 0.069811491900728204, 0.064215951133206842, 0.064370685282068421, 0.08134872685640461],
"overall_att_se": 0.035044276020269743
},
"hc2_bm": {
"per_coef_se": [0.055501994847834073, 0.053348051350068385, 0.06354112948601906, 0.058782844441069397, 0.058847181337849344, 0.075290767121827779],
"per_coef_se": [0.055501994847833892, 0.05334805135006826, 0.063541129486019407, 0.058782844441069335, 0.058847181337849684, 0.075290767121827223],
"per_coef_df_satt": [18.095161160028869, 18.095161160028777, 20.439187947573622, 20.439187947573593, 15.498545101842772, 15.49854510184279],
"overall_att_se": 0.031917611670264516,
"overall_att_se": 0.031917611670264509,
"overall_att_contrast_dof": 28.533525200424727,
"aggregate_group_dof": {
"3": 18.95430345302632,
Expand All @@ -96,12 +96,12 @@
"aggregate_event_keys": [0, 1, 2, 3]
},
"classical": {
"per_coef_se": [0.067005350609178102, 0.067005350609178199, 0.070375557382814979, 0.070375557382815007, 0.069334111291963985, 0.069334111291964068],
"overall_att_se": 0.039913974880197489
"per_coef_se": [0.067005350609178213, 0.06700535060917831, 0.070375557382815104, 0.070375557382815118, 0.069334111291964096, 0.069334111291964179],
"overall_att_se": 0.039913974880197552
},
"hc2": {
"per_coef_se": [0.059361785012656779, 0.065622553464974559, 0.066582402900941334, 0.063499229589624784, 0.065073838228263084, 0.077454318870318936],
"overall_att_se": 0.038128767955083756
"per_coef_se": [0.059361785012656675, 0.065622553464974517, 0.066582402900941778, 0.063499229589624756, 0.065073838228263514, 0.077454318870318631],
"overall_att_se": 0.038128767955083867
},
"poisson": {
"per_coef_att": [0.37585848071536632, 0.45753651172887189, 0.13832354075117673, -0.0529794047075412, 0.071763305194286989, -0.11645797372587538],
Expand Down
Loading
Loading