Add capital income predictors to asset imputation QRF#546
Open
Add capital income predictors to asset imputation QRF#546
Conversation
The QRF model for imputing liquid assets (bank accounts, stocks, bonds) previously used only employment_income, age, demographics. This adds interest_income, dividend_income, and rental_income as predictors, which are strongly correlated with asset holdings and available in both SIPP (TINC_BANK, TINC_STMF, TINC_BOND, TINC_RENT) and CPS. Updated in three places to keep them consistent: - sipp.py (standalone model training) - cps.py (CPS variable extraction) - source_impute.py (calibration-time imputation) Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.6 <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
interest_income,dividend_income, andrental_incomeas predictors to the SIPP→CPS liquid asset imputation modelsipp.py(model training),cps.py(CPS extraction),source_impute.py(calibration-time imputation)Details
The QRF model imputing
bank_account_assets,stock_assets, andbond_assetsfrom SIPP 2023 to CPS previously used only:employment_income,age,is_female,is_married,count_under_18Now also uses:
interest_income(SIPP: TINC_BANK + TINC_BOND, annualized)dividend_income(SIPP: TINC_STMF, annualized)rental_income(SIPP: TINC_RENT, annualized)These map directly to CPS variables already available in the microdata.
Motivation
With the companion PR (PolicyEngine/policyengine-us#connect-snap-assets-to-microdata) connecting
snap_assetsto imputed liquid assets, the SNAP asset test now binds in microsimulation. Better asset imputation is needed to avoid over/under-counting households failing the asset test when modeling BBCE elimination.Test plan
liquid_assets.pklretrains with new predictors🤖 Generated with Claude Code