diff --git a/changelog_entry.yaml b/changelog_entry.yaml index af5448c..8b63c21 100644 --- a/changelog_entry.yaml +++ b/changelog_entry.yaml @@ -1,5 +1,4 @@ - bump: minor changes: added: - - 5% dropout in calibration. - - Code quality improvements. + - Add employer pension contributions. diff --git a/docs/_toc.yml b/docs/_toc.yml index 4b8640a..2b6fe13 100644 --- a/docs/_toc.yml +++ b/docs/_toc.yml @@ -3,3 +3,4 @@ root: intro chapters: - file: methodology.ipynb - file: validation.ipynb +- file: pension_contributions.ipynb diff --git a/docs/pension_contributions.ipynb b/docs/pension_contributions.ipynb new file mode 100644 index 0000000..e41b9d3 --- /dev/null +++ b/docs/pension_contributions.ipynb @@ -0,0 +1,25 @@ +{ + "cells": [ + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "# Pension contributions\n", + "\n", + "We take pension contributions from the FRS data where available. This includes:\n", + "\n", + "* Employee contributions (~£30 billion in FY2022)\n", + "* Personal contributions (~£5 billion in FY2022)\n", + "\n", + "We do not have data on employer contributions, but from aggregate data this is around [250% of employee contributions](https://www.gov.uk/government/statistics/workplace-pension-participation-and-savings-trends-2009-to-2022/workplace-pension-participation-and-savings-trends-of-eligible-employees-2009-to-2022). We apply this as a multiplier to estimate employer contributions for each worker." + ] + } + ], + "metadata": { + "language_info": { + "name": "python" + } + }, + "nbformat": 4, + "nbformat_minor": 2 +} diff --git a/policyengine_uk_data/datasets/frs/enhanced_frs.py b/policyengine_uk_data/datasets/frs/enhanced_frs.py index f0f5727..92844d9 100644 --- a/policyengine_uk_data/datasets/frs/enhanced_frs.py +++ b/policyengine_uk_data/datasets/frs/enhanced_frs.py @@ -56,7 +56,7 @@ class EnhancedFRS_2022_23(EnhancedFRS): input_frs = ExtendedFRS_2022_23 time_period = 2022 end_year = 2028 - url = "release://PolicyEngine/ukda/1.3.0/enhanced_frs_2022_23.h5" + url = "release://PolicyEngine/ukda/1.4.0/enhanced_frs_2022_23.h5" def reweight( diff --git a/policyengine_uk_data/datasets/frs/frs.py b/policyengine_uk_data/datasets/frs/frs.py index 2862df3..203ffc4 100644 --- a/policyengine_uk_data/datasets/frs/frs.py +++ b/policyengine_uk_data/datasets/frs/frs.py @@ -115,7 +115,7 @@ class FRS_2022_23(FRS): label = "FRS (2022-23)" file_path = STORAGE_FOLDER / "frs_2022_23.h5" time_period = 2022 - url = "release://PolicyEngine/ukda/1.3.0/frs_2022_23.h5" + url = "release://PolicyEngine/ukda/1.4.0/frs_2022_23.h5" def add_id_variables(frs: h5py.File, person: DataFrame, household: DataFrame): @@ -745,7 +745,7 @@ def add_expenses( * 52 ) - frs["private_pension_contributions"] = max_( + frs["personal_pension_contributions"] = max_( 0, sum_to_entity( pen_prov.PENAMT[pen_prov.STEMPPEN.isin((5, 6))], @@ -754,10 +754,13 @@ def add_expenses( ).clip(0, pen_prov.PENAMT.quantile(0.95)) * 52, ) - frs["occupational_pension_contributions"] = max_( + frs["employee_pension_contributions"] = max_( 0, sum_to_entity(job.DEDUC1.fillna(0), job.person_id, person.index) * 52, ) + frs["employer_pension_contributions"] = ( + frs["employee_pension_contributions"] * 2.5 + ) # Rough estimate based on aggregates. frs["housing_service_charges"] = ( pd.DataFrame( diff --git a/policyengine_uk_data/utils/imputations/income.py b/policyengine_uk_data/utils/imputations/income.py index 509e334..9110a5b 100644 --- a/policyengine_uk_data/utils/imputations/income.py +++ b/policyengine_uk_data/utils/imputations/income.py @@ -19,7 +19,6 @@ charitable_investment_gifts="GIFTINV", employment_expenses="EPB", other_deductions="MOTHDED", - pension_contributions="PENSRLF", person_weight="FACT", benunit_weight="FACT", household_weight="FACT", @@ -79,7 +78,6 @@ def generate_spi_table(spi: pd.DataFrame): "employment_expenses", "property_income", "gift_aid", - "pension_contributions", ]