Commit 8a76dea
Align state AGI-band convention with main SOI loop ([lower, upper)) (#775)
`_add_state_agi_metric_columns` used `(agi > lower) & (agi <= upper)`
(left-exclusive, right-inclusive) while the main SOI loop in
`build_loss_matrix` at line 425 uses `(agi >= lower) & (agi < upper)`
(left-inclusive, right-exclusive). Both loops read from the same SOI
CSV; the SOI data is published on the half-open `[lower, upper)`
convention, so the state-band loop was misclassifying records that
sit exactly on bucket boundaries.
Switch to the `[lower, upper)` convention for consistency with both
the main SOI loop and the underlying data.
Co-authored-by: Claude Opus 4.7 (1M context) <noreply@anthropic.com>1 parent 175b96d commit 8a76dea
2 files changed
Lines changed: 5 additions & 1 deletion
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1033 | 1033 | | |
1034 | 1034 | | |
1035 | 1035 | | |
1036 | | - | |
| 1036 | + | |
| 1037 | + | |
| 1038 | + | |
| 1039 | + | |
1037 | 1040 | | |
1038 | 1041 | | |
1039 | 1042 | | |
| |||
0 commit comments