policyengine-uk 2.49.5__py3-none-any.whl → 2.50.0__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Potentially problematic release.
This version of policyengine-uk might be problematic. Click here for more details.
- policyengine_uk/variables/household/income/hbai_household_net_income_ahc.py +13 -0
- policyengine_uk/variables/household/income/inflation_adjustment.py +24 -0
- {policyengine_uk-2.49.5.dist-info → policyengine_uk-2.50.0.dist-info}/METADATA +1 -1
- {policyengine_uk-2.49.5.dist-info → policyengine_uk-2.50.0.dist-info}/RECORD +6 -6
- {policyengine_uk-2.49.5.dist-info → policyengine_uk-2.50.0.dist-info}/WHEEL +0 -0
- {policyengine_uk-2.49.5.dist-info → policyengine_uk-2.50.0.dist-info}/licenses/LICENSE +0 -0
|
@@ -17,3 +17,16 @@ class hbai_household_net_income_ahc(Variable):
|
|
|
17
17
|
"mortgage_interest_repayment",
|
|
18
18
|
"structural_insurance_payments",
|
|
19
19
|
]
|
|
20
|
+
|
|
21
|
+
|
|
22
|
+
class real_hbai_household_net_income_ahc(Variable):
|
|
23
|
+
label = "real household net income after housing costs (HBAI definition)"
|
|
24
|
+
entity = Household
|
|
25
|
+
definition_period = YEAR
|
|
26
|
+
value_type = float
|
|
27
|
+
unit = GBP
|
|
28
|
+
|
|
29
|
+
def formula(household, period, parameters):
|
|
30
|
+
return household("hbai_household_net_income_ahc", period) * household(
|
|
31
|
+
"inflation_adjustment_ahc", period
|
|
32
|
+
)
|
|
@@ -19,3 +19,27 @@ class inflation_adjustment(Variable):
|
|
|
19
19
|
current_period_cpi = cpi(period)
|
|
20
20
|
now_cpi = cpi(datetime.datetime.now().strftime("%Y-01-01"))
|
|
21
21
|
return now_cpi / current_period_cpi
|
|
22
|
+
|
|
23
|
+
|
|
24
|
+
class inflation_adjustment_ahc(Variable):
|
|
25
|
+
label = f"inflation multiplier to get {datetime.datetime.now().year} after housing costs prices"
|
|
26
|
+
entity = Household
|
|
27
|
+
definition_period = YEAR
|
|
28
|
+
value_type = float
|
|
29
|
+
unit = "/1"
|
|
30
|
+
|
|
31
|
+
def formula(household, period, parameters):
|
|
32
|
+
cpi = (
|
|
33
|
+
parameters.gov.economic_assumptions.indices.obr.consumer_price_index
|
|
34
|
+
)
|
|
35
|
+
cpi_ahc = (
|
|
36
|
+
parameters.gov.economic_assumptions.indices.obr.consumer_price_index_ahc
|
|
37
|
+
)
|
|
38
|
+
|
|
39
|
+
cpi_ahc_val = cpi_ahc(period)
|
|
40
|
+
# Fall back to use cpi, for periods beyond 2029
|
|
41
|
+
if not cpi_ahc_val:
|
|
42
|
+
cpi_ahc_val = cpi(period)
|
|
43
|
+
|
|
44
|
+
now_cpi_ahc = cpi(datetime.datetime.now().strftime("%Y-01-01"))
|
|
45
|
+
return now_cpi_ahc / cpi_ahc_val
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: policyengine-uk
|
|
3
|
-
Version: 2.
|
|
3
|
+
Version: 2.50.0
|
|
4
4
|
Summary: PolicyEngine tax and benefit system for the UK.
|
|
5
5
|
Project-URL: Homepage, https://github.com/PolicyEngine/policyengine-uk
|
|
6
6
|
Project-URL: Repository, https://github.com/PolicyEngine/policyengine-uk
|
|
@@ -1267,7 +1267,7 @@ policyengine_uk/variables/household/income/hbai_benefits.py,sha256=IPitXWgJcUo9c
|
|
|
1267
1267
|
policyengine_uk/variables/household/income/hbai_excluded_income.py,sha256=UKYNFcfaP96xWYOnyEIe-0Z0hpDWBbbHpsJ-Ag6xKXM,477
|
|
1268
1268
|
policyengine_uk/variables/household/income/hbai_excluded_income_change.py,sha256=jHQs3HXBjx7cREp-ljf09DBnitdHSq9jrjVmKmbARRA,596
|
|
1269
1269
|
policyengine_uk/variables/household/income/hbai_household_net_income.py,sha256=Tuvf8VMdldmz7GiM4KxFW5a4EuR196bUkQfTAn8u0YE,2406
|
|
1270
|
-
policyengine_uk/variables/household/income/hbai_household_net_income_ahc.py,sha256=
|
|
1270
|
+
policyengine_uk/variables/household/income/hbai_household_net_income_ahc.py,sha256=KgBO-T2xrcBGF62kUkxmzpXbbyxid8avYowE817Wjmw,877
|
|
1271
1271
|
policyengine_uk/variables/household/income/hours_worked.py,sha256=hW4cUAV2xK3drDXXBmcqp5Soao4e7r9Xxfpwh7tBOx8,255
|
|
1272
1272
|
policyengine_uk/variables/household/income/household_benefits.py,sha256=8NVY3BuNiLLQ23IRSY0xoOE8AZP_e_I2j5h432cFPK4,2389
|
|
1273
1273
|
policyengine_uk/variables/household/income/household_gross_income.py,sha256=d-EDrcUslPKsIpYYboAngMCvdpVgt_g_tABneG8TFh8,444
|
|
@@ -1285,7 +1285,7 @@ policyengine_uk/variables/household/income/in_relative_poverty_ahc.py,sha256=335
|
|
|
1285
1285
|
policyengine_uk/variables/household/income/in_relative_poverty_bhc.py,sha256=Okhc5V844qoNhTPR5db_T8Kcq412BhfzenSDOUTjppg,525
|
|
1286
1286
|
policyengine_uk/variables/household/income/in_work.py,sha256=D5rBwUIb2WjIDZODI_4vVBTtCPsilvAkqoL8tuN653w,506
|
|
1287
1287
|
policyengine_uk/variables/household/income/income_decile.py,sha256=pcUUESL0K74YVFG0aismjk4IQTyGmTdmnnEI37UgZUQ,468
|
|
1288
|
-
policyengine_uk/variables/household/income/inflation_adjustment.py,sha256=
|
|
1288
|
+
policyengine_uk/variables/household/income/inflation_adjustment.py,sha256=C2cEUE02v5JdV_1q81z7s-UDhLbBGrZdYHOKX2GFGOQ,1394
|
|
1289
1289
|
policyengine_uk/variables/household/income/is_QYP.py,sha256=QlsndiWhoJLX-p0XRSRIQRnE73McnFJM7ra3C_7coTc,513
|
|
1290
1290
|
policyengine_uk/variables/household/income/is_apprentice.py,sha256=isDDLgrwhRGHLhl-0O_g_38A1UV82mqhVTp8noNLBH0,250
|
|
1291
1291
|
policyengine_uk/variables/household/income/is_child_or_QYP.py,sha256=c97SUoxXTklzBp4LJFrjv_wRr-W8E-Z3tIzp-1rDWn4,353
|
|
@@ -1387,7 +1387,7 @@ policyengine_uk/variables/misc/spi_imputed.py,sha256=iPVlBF_TisM0rtKvO-3-PQ2UYCe
|
|
|
1387
1387
|
policyengine_uk/variables/misc/uc_migrated.py,sha256=zFNcUJaO8gwmbL1iY9GKgUt3G6J9yrCraqBV_5dCvlM,306
|
|
1388
1388
|
policyengine_uk/variables/misc/categories/lower_middle_or_higher.py,sha256=C54tHYz2DmOyvQYCC1bF8RJwRZinhAq_e3aYC-9F5fM,157
|
|
1389
1389
|
policyengine_uk/variables/misc/categories/lower_or_higher.py,sha256=81NIbLLabRr9NwjpUZDuV8IV8_mqmp5NM-CZvt55TwE,129
|
|
1390
|
-
policyengine_uk-2.
|
|
1391
|
-
policyengine_uk-2.
|
|
1392
|
-
policyengine_uk-2.
|
|
1393
|
-
policyengine_uk-2.
|
|
1390
|
+
policyengine_uk-2.50.0.dist-info/METADATA,sha256=JOij1Pjkmwox1BueOpJh3t37F2GVvrH-_08qRI8s2P8,3995
|
|
1391
|
+
policyengine_uk-2.50.0.dist-info/WHEEL,sha256=qtCwoSJWgHk21S1Kb4ihdzI2rlJ1ZKaIurTj_ngOhyQ,87
|
|
1392
|
+
policyengine_uk-2.50.0.dist-info/licenses/LICENSE,sha256=dql8h4yceoMhuzlcK0TT_i-NgTFNIZsgE47Q4t3dUYI,34520
|
|
1393
|
+
policyengine_uk-2.50.0.dist-info/RECORD,,
|
|
File without changes
|
|
File without changes
|