Fill 2020 and 2021 carbon intensities by interpolation (#396)#1639
Merged
Fill 2020 and 2021 carbon intensities by interpolation (#396)#1639
Conversation
DEFRA's UK Carbon Footprint dataset publishes annual COICOP multipliers but only at 3-digit COICOP — aggregation to PE's 12 2-digit categories needs LCFS expenditure weighting and we don't have the methodology used to produce the existing 2019 / 2022 values in the YAML. Use linear interpolation between those two anchors as a transparent stop-gap, so simulations covering 2020 or 2021 use plausible intermediate values instead of the prior `backdate_parameters` artifact that held everything flat at 2019. Years after 2022 continue to be forward-projected at -4.9%/year via `gov.economic_assumptions.indices.carbon_intensity`, since DEFRA outturn for 2023+ has not yet been published (DEFRA runs roughly a 2.5-year lag on consumption-based emissions). Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
MaxGhenis
approved these changes
Apr 20, 2026
Collaborator
MaxGhenis
left a comment
There was a problem hiding this comment.
Verified the linear interpolation math against 6 categories — all match to within floating-point tolerance. Better than the prior backdate_parameters flat-hold artefact. Description note that DEFRA publishes COICOP figures but we lack the LCFS-weighted aggregation is a fair caveat — linear interpolation between the methodology-consistent 2019/2022 anchors is the right fallback.
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
backdate_parametersstep.intensity.yamlcategories (linear between the existing DEFRA-sourced 2019 and 2022 anchors), so simulations covering those years use plausible intermediate values instead of a backdate artifact.descriptionto document the source / methodology / forward-projection.Why interpolation, not DEFRA outturn
DEFRA's UK Carbon Footprint dataset does publish annual COICOP multipliers for 2020 and 2021, but only at 3-digit COICOP (~110 sub-categories like "1.1.1 Bread and cereals"). PolicyEngine's 12 categories are 2-digit roll-ups, and the existing 2019/2022 values in the YAML were produced by some LCFS expenditure-weighted aggregation whose methodology isn't captured anywhere in the repo. Back-casting with a different aggregation would put the new years on a different scale than the existing two anchors and introduce a discontinuity. Linear interpolation between two real DEFRA-anchored values is honest — it's clearly an estimate and the YAML description says so.
If anyone later sources the original LCFS-weighting methodology, the interpolated 2020 / 2021 figures (and ideally the full 1990-2018 history) can be replaced with proper DEFRA-derived values.
What about post-2022?
DEFRA runs roughly a 2.5-year lag on consumption-based emissions (the 2022 release was published 14 May 2025), so 2023, 2024, 2025 and 2026 outturn aren't published yet. The model continues to forward-project these via
gov.economic_assumptions.yoy_growth.carbon_intensityat -4.9%/year, which is propagated throughgov.economic_assumptions.indices.carbon_intensityand applied as theupratingsource onintensity.yaml. As DEFRA publishes more recent outturn years, those should be appended to the YAML directly so the projection only kicks in past the most recent published year.Test plan
make formatclean🤖 Generated with Claude Code