Carry FRS employer sector (mjobsect) and SIC industry into the dataset#433
Open
vahid-ahmadi wants to merge 2 commits into
Open
Carry FRS employer sector (mjobsect) and SIC industry into the dataset#433vahid-ahmadi wants to merge 2 commits into
vahid-ahmadi wants to merge 2 commits into
Conversation
Populate the new employment_sector (public/private, from FRS mjobsect) and sic_industry_division (SIC 2007, from FRS sic) Person-level variables, using the same categorical() passthrough pattern as employment_status and region. Requires the matching variables in policyengine-uk (PolicyEngine/policyengine-uk#1785). Closes #432 Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.8 (1M context) <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.
What this does
Carries two existing FRS fields into the dataset (passthrough, not imputation — they're already in the FRS spine), populating the new Person-level variables added in PolicyEngine/policyengine-uk#1785:
employment_sector← FRSmjobsect(public/private of main job), viacategorical()→NOT_EMPLOYED/PRIVATE/PUBLIC.sic_industry_division← FRSsic(SIC 2007 division; 84 = public administration & defence).Mirrors the existing handling of
employment_status(fromempstati),region(fromgvtregno), andtenure_type(fromptentyp2).Validation (raw FRS 2022-23 person frame)
employment_sector= PUBLICmjobsect == 2employment_sector= PRIVATEemployment_sector= NOT_EMPLOYEDsic_industry_division == 84(public admin)Ordering
Depends on PolicyEngine/policyengine-uk#1785 (which defines the variables); that PR must merge/release first or the dataset build will not recognise the new variables.
Closes #432.
🤖 Generated with Claude Code