Skip to content
Merged
1 change: 1 addition & 0 deletions changelog.d/state-pension-age-67-phase-in-dates.fixed.md
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
- Removed NumPy's generic-timedelta deprecation warning from State Pension date arithmetic without changing calculated dates.
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
- Household calculations default an unspecified birthday position to six months before 6 October, implying a 6 April birth date and making an entered age of 66 above State Pension age at that check in 2026-27 and below it in 2027-28, while fractional ages or `months_since_last_birthday` can specify a different inferred birth date even when other people supply birthday months.
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
- Added replacement guidance for reforms, structural reforms, nested scenarios and saved API policies using the removed male and female State Pension age parameters, rejecting obsolete simulation changes before resetting existing policy.
1 change: 1 addition & 0 deletions changelog.d/state-pension-age-67-phase-in.added.md
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
Add `months_since_last_birthday`, which places a person's date of birth within their year of age, and `months_since_state_pension_age`.
1 change: 1 addition & 0 deletions changelog.d/state-pension-age-67-phase-in.fixed.md
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
Set State Pension age from each person's date of birth under Pensions Act 1995 Schedule 4 paragraph 1, including the rise from 66 to 67 for people born on or after 6 April 1960 (Pensions Act 2014 s.26): 66-year-olds move below State Pension age through 2026-27 and 2027-28, and are all below it from 2028-29. The Savings Credit age test, the split between basic and new State Pension, and additional State Pension now follow each person's own State Pension age.
1 change: 1 addition & 0 deletions changelog.d/state-pension-age-67-phase-in.removed.md
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
Remove `gov.dwp.state_pension.age.male` and `gov.dwp.state_pension.age.female`, a single State Pension age for each year. The statutory timetable by date of birth replaces them: `gov.dwp.state_pension.age.age_by_birth_date` (the age, in months) and `day_by_birth_date` (the day), with `male.age` and `male.born_before` for men born before 6 December 1953. A reform to State Pension age now changes those rows, for example the ages for births from a given date; code that read a State Pension age should read `state_pension_age` or `is_SP_age`.
63 changes: 62 additions & 1 deletion docs/book/programs/gov/dwp/state-pension.md
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,68 @@ Three variables under `gov/dwp/`:

The flag-up split (`state_pension_type`) is settled by [PR #1618](https://github.com/PolicyEngine/policyengine-uk/pull/1618):
classification is based on whether the person reaches State Pension age
before or on/after 6 April 2016.
before or on/after 6 April 2016. No component is paid before State
Pension age.

## State Pension age

State Pension age depends on date of birth. Pensions Act 1995 Schedule 4
paragraph 1 sets it for each birth period, either as an age or as the day
on which it is attained, and the Pensions Act 2014 s.26 raises it from 66
to 67 for people born on or after 6 April 1960: 66 years and 1 to 11
months for births from 6 April 1960 to 5 March 1961, and 67 from 6 March
1961. The parameters under `gov/dwp/state_pension/age/` encode that
timetable row by row:

- `age_by_birth_date` — the age, in months, by date of birth (women, and
men born on or after 6 December 1953);
- `day_by_birth_date` — the day, where the statute sets a day instead;
- `male/age` and `male/born_before` — rule (1): men born before 6
December 1953 attain it at 65.

A person attains State Pension age on the later of the two. The model
places each person's date of birth with `age` and
`months_since_last_birthday`, which counts months since their last
birthday on 6 October, the middle of the fiscal year:

- `state_pension_age` is the person's own State Pension age;
- `months_since_state_pension_age` is how long before 6 October they
attained it (negative if later);
- `is_SP_age` is whether they have attained it by 6 October, so are over
it for most of the year.

Simulations of a household situation take a whole age to be the middle of
the year of age (six months since the birthday); a fractional age is read as
the exact age on 6 October, overriding `months_since_last_birthday` even
when another person supplies birthday months. The default implies a birth
date of 6 April: an entered age of 66 is above State Pension age at the
6 October check in 2026-27 and below it in 2027-28. Set a fractional age
or `months_since_last_birthday` to specify a different inferred birth date.
Survey microdata records whole years only, so in
simulations built from data, including a region or constituency filtered
from it, each single year of age and sex is spread evenly over the year by
weight, and `filter_dataset` carries each person's place into a household it
extracts. The weighted share of each age over State Pension age then matches
the statute: three quarters of 66-year-olds in 2026-27, a quarter in 2027-28
and none from 2028-29.

A person attains an age at the start of the anniversary of their birth
(Family Law Reform Act 1969 s.9(1)), and an age of "N years and M months" on
the same day of the month, or the month's last day where that day does not
exist; that also gives the three days rule (7A) sets. A reform can change the
age or day of any row, or where a row starts; a new phase-in that needs extra
rows, such as bringing forward the rise to 68, needs new rows in the
parameter files.

The removed scalar parameters `gov.dwp.state_pension.age.male` and `.female`
remain discoverable in metadata as migration nodes: explicit root `get_child`
lookups, updates, and scalar value-history reads for saved API policies raise
an error naming the birth-date
scales above. The `male.age` and `male.born_before` children remain available
for the earlier male cohorts. For example, reform
`gov.dwp.state_pension.age.age_by_birth_date[14].amount` to change the age
in months for births from 6 March 1961 until the next bracket; read individual
eligibility from `is_SP_age` or the individual threshold from `state_pension_age`.

## Uprating

Expand Down
19 changes: 16 additions & 3 deletions policyengine_uk/data/filter_dataset.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,8 @@
import typing

import numpy as np
import pandas as pd

if typing.TYPE_CHECKING:
from policyengine_uk import Microsimulation
from policyengine_uk.data import UKSingleYearDataset
Expand Down Expand Up @@ -33,9 +36,19 @@ def filter_dataset(
"""
dataset: UKSingleYearDataset = sim.dataset[year]
new_dataset = dataset.copy()
new_dataset.person = new_dataset.person[
new_dataset.person.person_household_id == household_id
]
person = new_dataset.person
if "months_since_last_birthday" not in person.columns:
# Birthdays are spread over the year across the whole population, so
# carry each person's place across rather than recompute it for one
# household.
months = pd.Series(
np.asarray(sim.calculate("months_since_last_birthday", year)),
index=np.asarray(sim.calculate("person_id", year)),
)
person = person.assign(
months_since_last_birthday=months.loc[person.person_id].values
)
new_dataset.person = person[person.person_household_id == household_id]
new_dataset.household = new_dataset.household[
new_dataset.household.household_id == household_id
]
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
description: People reaching State Pension age after this year are not eligible for Savings Credit.
description: People who reach State Pension age on or after 6 April of this year are not eligible for Savings Credit.
metadata:
label: Savings Credit eligibility cutoff year
reference:
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
description: Savings Credit requires the claimant, or their partner, to have attained this age as well as State Pension age.
values:
2002-10-01: 65
metadata:
unit: year
label: Savings Credit minimum age
reference:
- title: State Pension Credit Act 2002, section 3(1)(a)
href: https://www.legislation.gov.uk/ukpga/2002/16/section/3
Original file line number Diff line number Diff line change
@@ -0,0 +1,119 @@
description: People attain State Pension age when they reach this age, which depends on their date of birth; zero where the statute sets a day instead of an age.
metadata:
type: single_amount
threshold_unit: date
amount_unit: month
label: State Pension age by date of birth
documentation: Applies to women, and to men born on or after 6 December 1953; men born earlier follow the male rule. Where the statute sets the day on which State Pension age is attained, the amount is zero and day_by_birth_date gives the day. A person attains State Pension age on the later of the two.
reference:
- title: Pensions Act 1995, Schedule 4, paragraph 1 (rules for determining pensionable age)
href: https://www.legislation.gov.uk/ukpga/1995/26/schedule/4
- title: Pensions Act 2014, section 26 (increase in pensionable age to 67)
href: https://www.legislation.gov.uk/ukpga/2014/19/section/26
- title: Pensions Act 2011, section 1 (equalisation and increase to 66)
href: https://www.legislation.gov.uk/ukpga/2011/19/section/1
- title: Pensions Act 2007, section 13 (increases to 66, 67 and 68)
href: https://www.legislation.gov.uk/ukpga/2007/22/section/13
- title: Pensions (Northern Ireland) Order 1995, Schedule 2, paragraph 1 (the same timetable for Northern Ireland, with each rule numbered one higher)
href: https://www.legislation.gov.uk/nisi/1995/3213/schedule/2

# The timetable is keyed from the Pensions Act 1995 and reflects its current
# text, last amended by the Pensions Act 2014 (section 26, in force 14 July
# 2014). Earlier versions are not encoded separately: every amendment moved
# only people who had not yet reached pensionable age, so the timetable gives
# the right status for any past date.
#
# Dates of birth and days are written as YYYYMMDD numbers. Each bracket runs
# from its threshold (inclusive) to the next threshold.

# An age of N years and M months is attained on the same day of the month, or
# on the month's last day where that day does not exist. That gives the three
# days rule (7A) sets for table 3: 30 November 2026 for a birthday on 31 July
# 1960, 30 September 2027 for 31 December 1960 and 30 November 2027 for 31
# January 1961.
brackets:
# Rule (2): a woman born before 6th April 1950 attains pensionable age when she attains the age of 60.
- threshold:
1995-07-19: 0
amount:
1995-07-19: 720
# Rules (3) and (5), tables 1 and 2: born 6th April 1950 to 5th October 1954, pensionable age is attained on the day shown in day_by_birth_date.
- threshold:
1995-07-19: 19500406
amount:
1995-07-19: 0
# Rule (6): a person born after 5th October 1954 but before 6th April 1960 attains pensionable age when the person attains the age of 66.
- threshold:
1995-07-19: 19541006
amount:
1995-07-19: 792
# Rule (7), table 3: 6th April 1960 to 5th May 1960: 66 years and 1 month.
- threshold:
1995-07-19: 19600406
amount:
1995-07-19: 793
# Rule (7), table 3: 6th May 1960 to 5th June 1960: 66 years and 2 months.
- threshold:
1995-07-19: 19600506
amount:
1995-07-19: 794
# Rule (7), table 3: 6th June 1960 to 5th July 1960: 66 years and 3 months.
- threshold:
1995-07-19: 19600606
amount:
1995-07-19: 795
# Rule (7), table 3: 6th July 1960 to 5th August 1960: 66 years and 4 months.
- threshold:
1995-07-19: 19600706
amount:
1995-07-19: 796
# Rule (7), table 3: 6th August 1960 to 5th September 1960: 66 years and 5 months.
- threshold:
1995-07-19: 19600806
amount:
1995-07-19: 797
# Rule (7), table 3: 6th September 1960 to 5th October 1960: 66 years and 6 months.
- threshold:
1995-07-19: 19600906
amount:
1995-07-19: 798
# Rule (7), table 3: 6th October 1960 to 5th November 1960: 66 years and 7 months.
- threshold:
1995-07-19: 19601006
amount:
1995-07-19: 799
# Rule (7), table 3: 6th November 1960 to 5th December 1960: 66 years and 8 months.
- threshold:
1995-07-19: 19601106
amount:
1995-07-19: 800
# Rule (7), table 3: 6th December 1960 to 5th January 1961: 66 years and 9 months.
- threshold:
1995-07-19: 19601206
amount:
1995-07-19: 801
# Rule (7), table 3: 6th January 1961 to 5th February 1961: 66 years and 10 months.
- threshold:
1995-07-19: 19610106
amount:
1995-07-19: 802
# Rule (7), table 3: 6th February 1961 to 5th March 1961: 66 years and 11 months.
- threshold:
1995-07-19: 19610206
amount:
1995-07-19: 803
# Rule (8): a person born after 5th March 1961 but before 6th April 1977 attains pensionable age when the person attains the age of 67.
- threshold:
1995-07-19: 19610306
amount:
1995-07-19: 804
# Rule (9), table 4: born 6th April 1977 to 5th April 1978, pensionable age is attained on the day shown in day_by_birth_date.
- threshold:
1995-07-19: 19770406
amount:
1995-07-19: 0
# Rule (10): a person born after 5th April 1978 attains pensionable age when the person attains the age of 68.
- threshold:
1995-07-19: 19780406
amount:
1995-07-19: 816
Loading
Loading