Skip to content
Merged
Show file tree
Hide file tree
Changes from 6 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
33 changes: 32 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,35 @@
# PolicyEngine UK Data

PolicyEngine's project to build accurate UK household survey data.


## Public enhanced CPS

This repo now also includes a public calibrated microdata file:

- `policyengine_uk_data/storage/enhanced_cps_2025.h5`
- source manifest: `policyengine_uk_data/storage/enhanced_cps_source_2025.csv`

The UK enhanced CPS starts from PolicyBench's public 1,000-household CPS-derived
sample, maps those records into a `UKSingleYearDataset`, aligns core UK-facing
inputs such as council tax bands, vehicle ownership, pensions, disability/PIP,
consumption, and capital gains, and then recalibrates the household weights
against the UK national/region/country target registry used by the loss
pipeline.

On the native 2025 loss matrix, that alignment plus reweighting step cuts mean
absolute relative error from roughly `3.81` on the raw transfer weights to
roughly `0.39` on the calibrated dataset.

This is a public calibrated dataset, not a replacement for the FRS or enhanced
FRS. It is intended as the first step in a broader cross-country public-microdata
strategy.

Programmatic entrypoints:

- `policyengine_uk_data.datasets.create_enhanced_cps`
- `policyengine_uk_data.datasets.save_enhanced_cps`

Backward-compatible aliases remain available:

- `policyengine_uk_data.datasets.create_policybench_transfer`
- `policyengine_uk_data.datasets.save_policybench_transfer`
1 change: 1 addition & 0 deletions changelog.d/287.added.md
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
Added a public `enhanced_cps_2025` dataset constructor that maps PolicyBench's public 1,000-household CPS-derived sample into a `UKSingleYearDataset` and recalibrates household weights against the UK national/region/country target registry. Backward-compatible `policybench_transfer` aliases remain available.
25 changes: 25 additions & 0 deletions policyengine_uk_data/datasets/__init__.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
from .enhanced_cps import (
ENHANCED_CPS_FILE,
ENHANCED_CPS_SOURCE_FILE,
create_enhanced_cps,
save_enhanced_cps,
)
from .frs import create_frs
from .policybench_transfer import (
POLICYBENCH_TRANSFER_SOURCE_FILE,
create_policybench_transfer,
save_policybench_transfer,
)
from .spi import create_spi

__all__ = [
"ENHANCED_CPS_FILE",
"ENHANCED_CPS_SOURCE_FILE",
"create_enhanced_cps",
"POLICYBENCH_TRANSFER_SOURCE_FILE",
"create_frs",
"create_policybench_transfer",
"create_spi",
"save_enhanced_cps",
"save_policybench_transfer",
]
Loading
Loading