Fix NEED calibration to use gross income for income band assignment#288
Open
nikhilwoodruff wants to merge 3 commits intomainfrom
Open
Fix NEED calibration to use gross income for income band assignment#288nikhilwoodruff wants to merge 3 commits intomainfrom
nikhilwoodruff wants to merge 3 commits intomainfrom
Conversation
NEED 2023 income bands use Experian modelled gross household income, not net income. The previous code used hbai_household_net_income which misallocated households across bands (especially at extremes — too few in £100k+ bands). This switches to household_gross_income (LCFS P344p) for both the LCFS training calibration and the FRS 4D raking step. Co-Authored-By: Claude <noreply@anthropic.com>
Co-Authored-By: Claude <noreply@anthropic.com>
The test was evaluating NEED band fit using hbai_household_net_income while the raking now targets household_gross_income. Co-Authored-By: Claude <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
NEED 2023 income bands are based on Experian modelled gross household income, but the calibration code was using
hbai_household_net_income(disposable income after taxes) to assign households to bands. This caused high-income households to be placed in lower bands than they should be, and vice versa — the £100k-£150k and £150k+ bands had far too few households.This switches to
household_gross_income(LCFSP344pfor training data,household_gross_incomevariable for FRS raking) in both calibration steps:_calibrate_energy_to_need)impute_consumption)The QRF model predictors are unchanged —
hbai_household_net_incomeremains a useful predictor for the consumption imputation model itself.Test plan