From 165b77b4f2447dec284ef6aaeef52b4ad07ea689 Mon Sep 17 00:00:00 2001 From: Ziming Date: Mon, 16 Nov 2026 18:02:44 -0500 Subject: [PATCH 1/7] Add shared electricity and natural gas provider inputs --- .../liheap-utility-provider-inputs.added.md | 1 + .../expense/utilities/electricity_provider.py | 39 +++++++++++++++++++ .../expense/utilities/natural_gas_provider.py | 37 ++++++++++++++++++ 3 files changed, 77 insertions(+) create mode 100644 changelog.d/liheap-utility-provider-inputs.added.md create mode 100644 policyengine_us/variables/household/expense/utilities/electricity_provider.py create mode 100644 policyengine_us/variables/household/expense/utilities/natural_gas_provider.py diff --git a/changelog.d/liheap-utility-provider-inputs.added.md b/changelog.d/liheap-utility-provider-inputs.added.md new file mode 100644 index 00000000000..5ef51d5f975 --- /dev/null +++ b/changelog.d/liheap-utility-provider-inputs.added.md @@ -0,0 +1 @@ +Add shared electricity and natural gas provider inputs for utility-dependent benefit rules. diff --git a/policyengine_us/variables/household/expense/utilities/electricity_provider.py b/policyengine_us/variables/household/expense/utilities/electricity_provider.py new file mode 100644 index 00000000000..3df6b1ee529 --- /dev/null +++ b/policyengine_us/variables/household/expense/utilities/electricity_provider.py @@ -0,0 +1,39 @@ +from policyengine_us.model_api import * + + +class ElectricityProvider(Enum): + UNSPECIFIED = "Unspecified" + AMEREN_ILLINOIS = "Ameren Illinois" + AVISTA = "Avista" + BLOCK_ISLAND_UTILITY_DISTRICT = "Block Island Utility District" + CLEAR_RIVER_ELECTRIC_AND_WATER_DISTRICT = ( + "Clear River Electric and Water District (formerly Pascoag)" + ) + COMED = "ComEd" + IDAHO_POWER = "Idaho Power" + RHODE_ISLAND_ENERGY = "Rhode Island Energy (Narragansett Electric)" + ROCKY_MOUNTAIN_POWER = "Rocky Mountain Power" + OTHER = "Other electricity provider" + + +class electricity_provider(Variable): + value_type = Enum + possible_values = ElectricityProvider + default_value = ElectricityProvider.UNSPECIFIED + entity = SPMUnit + definition_period = YEAR + label = "Electricity utility provider" + documentation = ( + "Company providing the home's electric distribution service, as named on " + "the utility bill. Report the distribution utility even when a separate " + "retailer supplies the energy. UNSPECIFIED means the company was not " + "reported; OTHER means a reported company outside the listed choices. " + "The choices initially cover named utilities needed for Idaho, Illinois " + "and Rhode Island heating assistance and can be extended for other " + "programs. This input does not imply program enrollment or bill receipt." + ) + reference = ( + "https://liheapch.acf.gov/docs/2026/benefits-matricies/ID_BenefitMatrix_Heating_2026.pdf#page=1", + "https://dceo.illinois.gov/communityservices/utilitybillassistance/howtoapply.html", + "https://webserver.rilegislature.gov/Statutes/TITLE39/39-1/39-1-27.12.htm", + ) diff --git a/policyengine_us/variables/household/expense/utilities/natural_gas_provider.py b/policyengine_us/variables/household/expense/utilities/natural_gas_provider.py new file mode 100644 index 00000000000..348a15a3d34 --- /dev/null +++ b/policyengine_us/variables/household/expense/utilities/natural_gas_provider.py @@ -0,0 +1,37 @@ +from policyengine_us.model_api import * + + +class NaturalGasProvider(Enum): + UNSPECIFIED = "Unspecified" + AMEREN_ILLINOIS = "Ameren Illinois" + AVISTA = "Avista" + INTERMOUNTAIN_GAS = "Intermountain Gas" + NICOR_GAS = "Nicor Gas" + NORTH_SHORE_GAS = "North Shore Gas" + PEOPLES_GAS = "Peoples Gas" + RHODE_ISLAND_ENERGY = "Rhode Island Energy (Narragansett Electric)" + OTHER = "Other natural gas provider" + + +class natural_gas_provider(Variable): + value_type = Enum + possible_values = NaturalGasProvider + default_value = NaturalGasProvider.UNSPECIFIED + entity = SPMUnit + definition_period = YEAR + label = "Natural gas utility provider" + documentation = ( + "Company providing the home's natural gas distribution service, as named " + "on the utility bill. Report the distribution utility even when a " + "separate retailer supplies the gas. UNSPECIFIED means the company was " + "not reported; OTHER means a reported company outside the listed choices. " + "The choices initially cover named utilities needed for Idaho, Illinois " + "and Rhode Island heating assistance and can be extended for other " + "programs. Electricity and gas companies are reported independently. " + "This input does not imply program enrollment or bill receipt." + ) + reference = ( + "https://liheapch.acf.gov/docs/2026/benefits-matricies/ID_BenefitMatrix_Heating_2026.pdf#page=1", + "https://dceo.illinois.gov/communityservices/utilitybillassistance/howtoapply.html", + "https://webserver.rilegislature.gov/Statutes/TITLE39/39-1/39-1-27.12.htm", + ) From 2f37e76afcd123f1f61bce48b72bdbfe073d4d78 Mon Sep 17 00:00:00 2001 From: Ziming Date: Mon, 16 Nov 2026 18:07:48 -0500 Subject: [PATCH 2/7] Use named utility provider columns in Idaho LIHEAP --- .../id-liheap-utility-providers.added.md | 1 + .../payment/estimated_heating_costs.yaml | 20 +- .../liheap/payment/matrix/electricity.yaml | 6 +- .../payment/matrix/electricity_avista.yaml | 24 ++ .../matrix/electricity_rocky_mountain.yaml | 24 ++ .../liheap/payment/matrix/natural_gas.yaml | 6 +- .../payment/matrix/natural_gas_avista.yaml | 24 ++ .../gov/states/id/dhw/liheap/id_liheap.yaml | 265 ++++++++++++++++++ .../gov/states/id/dhw/liheap/id_liheap.py | 28 +- .../id_liheap_estimated_heating_cost.py | 26 +- 10 files changed, 412 insertions(+), 12 deletions(-) create mode 100644 changelog.d/id-liheap-utility-providers.added.md create mode 100644 policyengine_us/parameters/gov/states/id/dhw/liheap/payment/matrix/electricity_avista.yaml create mode 100644 policyengine_us/parameters/gov/states/id/dhw/liheap/payment/matrix/electricity_rocky_mountain.yaml create mode 100644 policyengine_us/parameters/gov/states/id/dhw/liheap/payment/matrix/natural_gas_avista.yaml diff --git a/changelog.d/id-liheap-utility-providers.added.md b/changelog.d/id-liheap-utility-providers.added.md new file mode 100644 index 00000000000..9842a0d713b --- /dev/null +++ b/changelog.d/id-liheap-utility-providers.added.md @@ -0,0 +1 @@ +Use Avista and Rocky Mountain Power provider columns for Idaho LIHEAP heating benefits and historical heating-cost estimates. diff --git a/policyengine_us/parameters/gov/states/id/dhw/liheap/payment/estimated_heating_costs.yaml b/policyengine_us/parameters/gov/states/id/dhw/liheap/payment/estimated_heating_costs.yaml index e27544cf740..e87f9febece 100644 --- a/policyengine_us/parameters/gov/states/id/dhw/liheap/payment/estimated_heating_costs.yaml +++ b/policyengine_us/parameters/gov/states/id/dhw/liheap/payment/estimated_heating_costs.yaml @@ -4,8 +4,9 @@ description: Idaho uses these estimated heating-season costs by fuel and heating # This table is not confirmed as current for FY2026. # The FY2026 anchor records this modeling assumption, not a verified update. # Preserve the published amounts without inflation or a twelve-month uplift. -# Provider groups are not distinguished. Electricity uses Idaho Power & -# Southern Utilities; natural gas uses the complete Intermountain Gas column. +# Unspecified/unlisted providers use Idaho Power & Southern Utilities for +# electricity and the complete Intermountain Gas column for natural gas. +# Avista and Rocky Mountain Power use their historical provider columns. # The old rent-cost column and old benefit percentages are not used. oil_or_propane: 1: @@ -35,6 +36,21 @@ coal_or_wood: 2025-10-01: 1_600 3: 2025-10-01: 1_800 +natural_gas_avista: + 1: + 2025-10-01: 875 + 2: + 2025-10-01: 1_200 +electricity_avista: + 1: + 2025-10-01: 1_450 + 2: + 2025-10-01: 1_585 +electricity_rocky_mountain: + 2: + 2025-10-01: 1_692 + 3: + 2025-10-01: 1_836 metadata: propagate_metadata_to_children: true diff --git a/policyengine_us/parameters/gov/states/id/dhw/liheap/payment/matrix/electricity.yaml b/policyengine_us/parameters/gov/states/id/dhw/liheap/payment/matrix/electricity.yaml index bb42cb0876e..e072615d616 100644 --- a/policyengine_us/parameters/gov/states/id/dhw/liheap/payment/matrix/electricity.yaml +++ b/policyengine_us/parameters/gov/states/id/dhw/liheap/payment/matrix/electricity.yaml @@ -1,8 +1,8 @@ description: Idaho provides this base electric-heating benefit by heating area and energy-burden group under the Low Income Home Energy Assistance Program. -# Electric utility-provider groups are not distinguished in the model for now. -# Use only the Idaho Power & Southern Utilities column; omit the Avista & -# Northern Utilities and Rocky Mountain Power columns. +# Idaho Power & Southern Utilities column, also used as the representative +# estimate for an unspecified/unlisted company or an unpublished combination. +# Named Avista and Rocky Mountain Power columns have separate parameters. # Heating areas 1-3 correspond to Areas I-III in the published chart. # Energy-burden groups: 1 = low, 2 = medium, 3 = high. 1: diff --git a/policyengine_us/parameters/gov/states/id/dhw/liheap/payment/matrix/electricity_avista.yaml b/policyengine_us/parameters/gov/states/id/dhw/liheap/payment/matrix/electricity_avista.yaml new file mode 100644 index 00000000000..5585891fd61 --- /dev/null +++ b/policyengine_us/parameters/gov/states/id/dhw/liheap/payment/matrix/electricity_avista.yaml @@ -0,0 +1,24 @@ +# Only published area/provider combinations are stored. +description: Idaho provides this base Avista electric heating benefit by heating area and energy-burden group under the Low Income Home Energy Assistance Program. +1: + 1: + '2025-10-01': 322 + 2: + '2025-10-01': 335 + 3: + '2025-10-01': 348 +2: + 1: + '2025-10-01': 371 + 2: + '2025-10-01': 387 + 3: + '2025-10-01': 402 +metadata: + propagate_metadata_to_children: true + unit: currency-USD + period: year + label: Idaho LIHEAP Avista electric heating benefit + reference: + - title: Idaho PY26 LIHEAP Benefit Determination Chart + href: https://liheapch.acf.gov/docs/2026/benefits-matricies/ID_BenefitMatrix_Heating_2026.pdf#page=1 diff --git a/policyengine_us/parameters/gov/states/id/dhw/liheap/payment/matrix/electricity_rocky_mountain.yaml b/policyengine_us/parameters/gov/states/id/dhw/liheap/payment/matrix/electricity_rocky_mountain.yaml new file mode 100644 index 00000000000..f613f960f95 --- /dev/null +++ b/policyengine_us/parameters/gov/states/id/dhw/liheap/payment/matrix/electricity_rocky_mountain.yaml @@ -0,0 +1,24 @@ +# Only published area/provider combinations are stored. +description: Idaho provides this base Rocky Mountain Power electric heating benefit by heating area and energy-burden group under the Low Income Home Energy Assistance Program. +2: + 1: + '2025-10-01': 407 + 2: + '2025-10-01': 424 + 3: + '2025-10-01': 441 +3: + 1: + '2025-10-01': 461 + 2: + '2025-10-01': 481 + 3: + '2025-10-01': 500 +metadata: + propagate_metadata_to_children: true + unit: currency-USD + period: year + label: Idaho LIHEAP Rocky Mountain Power electric heating benefit + reference: + - title: Idaho PY26 LIHEAP Benefit Determination Chart + href: https://liheapch.acf.gov/docs/2026/benefits-matricies/ID_BenefitMatrix_Heating_2026.pdf#page=1 diff --git a/policyengine_us/parameters/gov/states/id/dhw/liheap/payment/matrix/natural_gas.yaml b/policyengine_us/parameters/gov/states/id/dhw/liheap/payment/matrix/natural_gas.yaml index 616f0b94cde..919be8fb873 100644 --- a/policyengine_us/parameters/gov/states/id/dhw/liheap/payment/matrix/natural_gas.yaml +++ b/policyengine_us/parameters/gov/states/id/dhw/liheap/payment/matrix/natural_gas.yaml @@ -1,8 +1,8 @@ description: Idaho provides this base natural gas heating benefit by heating area and energy-burden group under the Low Income Home Energy Assistance Program. -# Natural gas provider groups are not distinguished in the model for now. -# Use the Intermountain Gas column, the only one filled in all three areas; -# omit the Avista column. Matches estimated_heating_costs. +# Intermountain Gas column, also used as the representative estimate for an +# unspecified/unlisted company or an unpublished combination. Avista has a +# separate parameter. Matches estimated_heating_costs. # Heating areas 1-3 correspond to Areas I-III in the published chart. # Energy-burden groups: 1 = low, 2 = medium, 3 = high. 1: diff --git a/policyengine_us/parameters/gov/states/id/dhw/liheap/payment/matrix/natural_gas_avista.yaml b/policyengine_us/parameters/gov/states/id/dhw/liheap/payment/matrix/natural_gas_avista.yaml new file mode 100644 index 00000000000..51764660ea9 --- /dev/null +++ b/policyengine_us/parameters/gov/states/id/dhw/liheap/payment/matrix/natural_gas_avista.yaml @@ -0,0 +1,24 @@ +# Only published area/provider combinations are stored. +description: Idaho provides this base Avista natural gas heating benefit by heating area and energy-burden group under the Low Income Home Energy Assistance Program. +1: + 1: + '2025-10-01': 168 + 2: + '2025-10-01': 176 + 3: + '2025-10-01': 183 +2: + 1: + '2025-10-01': 194 + 2: + '2025-10-01': 203 + 3: + '2025-10-01': 211 +metadata: + propagate_metadata_to_children: true + unit: currency-USD + period: year + label: Idaho LIHEAP Avista natural gas heating benefit + reference: + - title: Idaho PY26 LIHEAP Benefit Determination Chart + href: https://liheapch.acf.gov/docs/2026/benefits-matricies/ID_BenefitMatrix_Heating_2026.pdf#page=1 diff --git a/policyengine_us/tests/policy/baseline/gov/states/id/dhw/liheap/id_liheap.yaml b/policyengine_us/tests/policy/baseline/gov/states/id/dhw/liheap/id_liheap.yaml index 122e2536bc4..6b20c2993a9 100644 --- a/policyengine_us/tests/policy/baseline/gov/states/id/dhw/liheap/id_liheap.yaml +++ b/policyengine_us/tests/policy/baseline/gov/states/id/dhw/liheap/id_liheap.yaml @@ -323,3 +323,268 @@ id_aabd: 636 id_liheap_countable_income: 12_564 id_liheap: 367 + +# FY2026 chart, provider columns; low/medium/high using PY2007 costs. +- name: Named Avista electric provider selects each published burden and area cell. + period: 2026 + input: + state_code: + - ID + - ID + - ID + - ID + - ID + - ID + county: + - ADA_COUNTY_ID + - ADA_COUNTY_ID + - ADA_COUNTY_ID + - BANNOCK_COUNTY_ID + - BANNOCK_COUNTY_ID + - BANNOCK_COUNTY_ID + heating_type: + - ELECTRICITY + - ELECTRICITY + - ELECTRICITY + - ELECTRICITY + - ELECTRICITY + - ELECTRICITY + electricity_provider: + - AVISTA + - AVISTA + - AVISTA + - AVISTA + - AVISTA + - AVISTA + id_liheap_countable_income: + - 40000 + - 20000 + - 4000 + - 40000 + - 20000 + - 4000 + id_liheap_income_eligible: + - true + - true + - true + - true + - true + - true + has_heating_expense: + - true + - true + - true + - true + - true + - true + output: + id_liheap: + - 322 + - 335 + - 348 + - 371 + - 387 + - 402 + +# FY2026 chart, provider columns; low/medium/high using PY2007 costs. +- name: Named Rocky Mountain Power electric provider selects each published burden and area cell. + period: 2026 + input: + state_code: + - ID + - ID + - ID + - ID + - ID + - ID + county: + - BANNOCK_COUNTY_ID + - BANNOCK_COUNTY_ID + - BANNOCK_COUNTY_ID + - BEAR_LAKE_COUNTY_ID + - BEAR_LAKE_COUNTY_ID + - BEAR_LAKE_COUNTY_ID + heating_type: + - ELECTRICITY + - ELECTRICITY + - ELECTRICITY + - ELECTRICITY + - ELECTRICITY + - ELECTRICITY + electricity_provider: + - ROCKY_MOUNTAIN_POWER + - ROCKY_MOUNTAIN_POWER + - ROCKY_MOUNTAIN_POWER + - ROCKY_MOUNTAIN_POWER + - ROCKY_MOUNTAIN_POWER + - ROCKY_MOUNTAIN_POWER + id_liheap_countable_income: + - 40000 + - 20000 + - 4000 + - 40000 + - 20000 + - 4000 + id_liheap_income_eligible: + - true + - true + - true + - true + - true + - true + has_heating_expense: + - true + - true + - true + - true + - true + - true + output: + id_liheap: + - 407 + - 424 + - 441 + - 461 + - 481 + - 500 + +# FY2026 chart, provider columns; low/medium/high using PY2007 costs. +- name: Named Avista gas provider selects each published burden and area cell. + period: 2026 + input: + state_code: + - ID + - ID + - ID + - ID + - ID + - ID + county: + - ADA_COUNTY_ID + - ADA_COUNTY_ID + - ADA_COUNTY_ID + - BANNOCK_COUNTY_ID + - BANNOCK_COUNTY_ID + - BANNOCK_COUNTY_ID + heating_type: + - NATURAL_GAS + - NATURAL_GAS + - NATURAL_GAS + - NATURAL_GAS + - NATURAL_GAS + - NATURAL_GAS + natural_gas_provider: + - AVISTA + - AVISTA + - AVISTA + - AVISTA + - AVISTA + - AVISTA + id_liheap_countable_income: + - 40000 + - 14000 + - 4000 + - 40000 + - 14000 + - 4000 + id_liheap_income_eligible: + - true + - true + - true + - true + - true + - true + has_heating_expense: + - true + - true + - true + - true + - true + - true + output: + id_liheap: + - 168 + - 176 + - 183 + - 194 + - 203 + - 211 + +# 1335/24000 < 6%, whereas 1450/24000 >= 6%. +- name: Provider-specific cost changes the burden group before the benefit lookup. + period: 2026 + input: + state_code: + - ID + - ID + county: + - ADA_COUNTY_ID + - ADA_COUNTY_ID + heating_type: + - ELECTRICITY + - ELECTRICITY + electricity_provider: + - IDAHO_POWER + - AVISTA + id_liheap_countable_income: + - 24000 + - 24000 + id_liheap_income_eligible: + - true + - true + has_heating_expense: + - true + - true + output: + id_liheap_estimated_heating_cost: + - 1335 + - 1450 + id_liheap: + - 328 + - 335 + +# These are fallback estimates, not published awards for the blank cells. +- name: Unpublished provider area combinations retain the documented representative estimate. + period: 2026 + input: + state_code: + - ID + - ID + - ID + county: + - ADA_COUNTY_ID + - BEAR_LAKE_COUNTY_ID + - BEAR_LAKE_COUNTY_ID + heating_type: + - ELECTRICITY + - ELECTRICITY + - NATURAL_GAS + electricity_provider: + - ROCKY_MOUNTAIN_POWER + - AVISTA + - UNSPECIFIED + natural_gas_provider: + - UNSPECIFIED + - UNSPECIFIED + - AVISTA + id_liheap_countable_income: + - 4000 + - 4000 + - 4000 + id_liheap_income_eligible: + - true + - true + - true + has_heating_expense: + - true + - true + - true + output: + id_liheap_estimated_heating_cost: + - 1335 + - 1605 + - 1207 + id_liheap: + - 355 + - 464 + - 173 diff --git a/policyengine_us/variables/gov/states/id/dhw/liheap/id_liheap.py b/policyengine_us/variables/gov/states/id/dhw/liheap/id_liheap.py index 06e83a89f2c..3dc028d36c9 100644 --- a/policyengine_us/variables/gov/states/id/dhw/liheap/id_liheap.py +++ b/policyengine_us/variables/gov/states/id/dhw/liheap/id_liheap.py @@ -31,6 +31,30 @@ def formula(spm_unit, period, parameters): area = clip(spm_unit("id_liheap_heating_area", period), 1, 3) heating = spm_unit("heating_type", period) types = heating.possible_values + electric_provider = spm_unit("electricity_provider", period) + gas_provider = spm_unit("natural_gas_provider", period) + electric_providers = electric_provider.possible_values + # The chart leaves Avista Area III and Rocky Mountain Area I blank. + # Retain the representative-column estimate for those combinations, + # unspecified companies and unlisted smaller utilities. + avista_electric = (electric_provider == electric_providers.AVISTA) & (area < 3) + rocky_mountain = ( + electric_provider == electric_providers.ROCKY_MOUNTAIN_POWER + ) & (area > 1) + electric_amount = select( + [avista_electric, rocky_mountain], + [ + p.matrix.electricity_avista[min_(area, 2)][burden_group], + p.matrix.electricity_rocky_mountain[max_(area, 2)][burden_group], + ], + default=p.matrix.electricity[area][burden_group], + ) + avista_gas = (gas_provider == gas_provider.possible_values.AVISTA) & (area < 3) + gas_amount = where( + avista_gas, + p.matrix.natural_gas_avista[min_(area, 2)][burden_group], + p.matrix.natural_gas[area][burden_group], + ) chart_amount = select( [ (heating == types.ELECTRICITY) | (heating == types.SOLAR), @@ -41,8 +65,8 @@ def formula(spm_unit, period, parameters): (heating == types.COAL) | (heating == types.WOOD), ], [ - p.matrix.electricity[area][burden_group], - p.matrix.natural_gas[area][burden_group], + electric_amount, + gas_amount, p.matrix.oil_or_propane[area][burden_group], p.matrix.coal_or_wood[area][burden_group], ], diff --git a/policyengine_us/variables/gov/states/id/dhw/liheap/id_liheap_estimated_heating_cost.py b/policyengine_us/variables/gov/states/id/dhw/liheap/id_liheap_estimated_heating_cost.py index 5e3443a285a..d90805ae9a9 100644 --- a/policyengine_us/variables/gov/states/id/dhw/liheap/id_liheap_estimated_heating_cost.py +++ b/policyengine_us/variables/gov/states/id/dhw/liheap/id_liheap_estimated_heating_cost.py @@ -20,6 +20,28 @@ def formula(spm_unit, period, parameters): # No Idaho source names solar or kerosene. As in heating_expense, solar # reads as electric and kerosene as the chart's oil. lookup_area = clip(area, 1, 3) + electric_provider = spm_unit("electricity_provider", period) + gas_provider = spm_unit("natural_gas_provider", period) + electric_providers = electric_provider.possible_values + # As with the payment chart, blank historical combinations retain + # the existing representative estimate instead of asserting zero cost. + electric_cost = select( + [ + (electric_provider == electric_providers.AVISTA) & (area < 3), + (electric_provider == electric_providers.ROCKY_MOUNTAIN_POWER) + & (area > 1), + ], + [ + p.electricity_avista[min_(lookup_area, 2)], + p.electricity_rocky_mountain[max_(lookup_area, 2)], + ], + default=p.electricity[lookup_area], + ) + gas_cost = where( + (gas_provider == gas_provider.possible_values.AVISTA) & (area < 3), + p.natural_gas_avista[min_(lookup_area, 2)], + p.natural_gas[lookup_area], + ) cost = select( [ (heating == types.ELECTRICITY) | (heating == types.SOLAR), @@ -30,8 +52,8 @@ def formula(spm_unit, period, parameters): (heating == types.COAL) | (heating == types.WOOD), ], [ - p.electricity[lookup_area], - p.natural_gas[lookup_area], + electric_cost, + gas_cost, p.oil_or_propane[lookup_area], p.coal_or_wood[lookup_area], ], From d8304d16cb9bcdb1d36a89524d006af3b5805b51 Mon Sep 17 00:00:00 2001 From: Ziming Date: Tue, 17 Nov 2026 10:43:01 -0500 Subject: [PATCH 3/7] Add named northern Idaho electric companies to shared input --- .../household/expense/utilities/electricity_provider.py | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/policyengine_us/variables/household/expense/utilities/electricity_provider.py b/policyengine_us/variables/household/expense/utilities/electricity_provider.py index 3df6b1ee529..e4f4592056a 100644 --- a/policyengine_us/variables/household/expense/utilities/electricity_provider.py +++ b/policyengine_us/variables/household/expense/utilities/electricity_provider.py @@ -6,11 +6,18 @@ class ElectricityProvider(Enum): AMEREN_ILLINOIS = "Ameren Illinois" AVISTA = "Avista" BLOCK_ISLAND_UTILITY_DISTRICT = "Block Island Utility District" + BONNERS_FERRY_LIGHT_AND_WATER = "Bonners Ferry Light and Water" CLEAR_RIVER_ELECTRIC_AND_WATER_DISTRICT = ( "Clear River Electric and Water District (formerly Pascoag)" ) + CLEARWATER_POWER = "Clearwater Power" COMED = "ComEd" + IDAHO_COUNTY_LIGHT_AND_POWER = "Idaho County Light and Power" IDAHO_POWER = "Idaho Power" + INLAND_POWER_AND_LIGHT = "Inland Power and Light" + KOOTENAI_ELECTRIC = "Kootenai Electric Cooperative" + NORTHERN_LIGHTS = "Northern Lights Incorporated" + PLUMMER_ELECTRIC = "Plummer Electric Department" RHODE_ISLAND_ENERGY = "Rhode Island Energy (Narragansett Electric)" ROCKY_MOUNTAIN_POWER = "Rocky Mountain Power" OTHER = "Other electricity provider" @@ -36,4 +43,6 @@ class electricity_provider(Variable): "https://liheapch.acf.gov/docs/2026/benefits-matricies/ID_BenefitMatrix_Heating_2026.pdf#page=1", "https://dceo.illinois.gov/communityservices/utilitybillassistance/howtoapply.html", "https://webserver.rilegislature.gov/Statutes/TITLE39/39-1/39-1-27.12.htm", + "https://oemr.idaho.gov/utilities/", + "https://www.inlandpower.com/", ) From 2a5ced29c7fd58f987ce93fd88458cfb50999067 Mon Sep 17 00:00:00 2001 From: Ziming Date: Tue, 17 Nov 2026 10:47:15 -0500 Subject: [PATCH 4/7] Map named northern Idaho utilities to LIHEAP provider columns --- .../id-liheap-utility-providers.added.md | 2 +- .../payment/estimated_heating_costs.yaml | 5 ++- .../liheap/payment/matrix/electricity.yaml | 2 +- ..._avista.yaml => electricity_northern.yaml} | 4 +- .../payment/northern_electric_providers.yaml | 28 ++++++++++++++ .../gov/states/id/dhw/liheap/id_liheap.yaml | 37 +++++++++++++++++++ .../gov/states/id/dhw/liheap/id_liheap.py | 12 +++--- .../id_liheap_estimated_heating_cost.py | 10 +++-- 8 files changed, 86 insertions(+), 14 deletions(-) rename policyengine_us/parameters/gov/states/id/dhw/liheap/payment/matrix/{electricity_avista.yaml => electricity_northern.yaml} (68%) create mode 100644 policyengine_us/parameters/gov/states/id/dhw/liheap/payment/northern_electric_providers.yaml diff --git a/changelog.d/id-liheap-utility-providers.added.md b/changelog.d/id-liheap-utility-providers.added.md index 9842a0d713b..ab0a5a9cd49 100644 --- a/changelog.d/id-liheap-utility-providers.added.md +++ b/changelog.d/id-liheap-utility-providers.added.md @@ -1 +1 @@ -Use Avista and Rocky Mountain Power provider columns for Idaho LIHEAP heating benefits and historical heating-cost estimates. +Use named northern utilities, Avista gas and Rocky Mountain Power provider columns for Idaho LIHEAP heating benefits and historical heating-cost estimates. diff --git a/policyengine_us/parameters/gov/states/id/dhw/liheap/payment/estimated_heating_costs.yaml b/policyengine_us/parameters/gov/states/id/dhw/liheap/payment/estimated_heating_costs.yaml index e87f9febece..d7ef1faea08 100644 --- a/policyengine_us/parameters/gov/states/id/dhw/liheap/payment/estimated_heating_costs.yaml +++ b/policyengine_us/parameters/gov/states/id/dhw/liheap/payment/estimated_heating_costs.yaml @@ -6,7 +6,8 @@ description: Idaho uses these estimated heating-season costs by fuel and heating # Preserve the published amounts without inflation or a twelve-month uplift. # Unspecified/unlisted providers use Idaho Power & Southern Utilities for # electricity and the complete Intermountain Gas column for natural gas. -# Avista and Rocky Mountain Power use their historical provider columns. +# Named northern utilities and Rocky Mountain Power use their historical +# provider columns. Northern membership follows northern_electric_providers. # The old rent-cost column and old benefit percentages are not used. oil_or_propane: 1: @@ -41,7 +42,7 @@ natural_gas_avista: 2025-10-01: 875 2: 2025-10-01: 1_200 -electricity_avista: +electricity_northern: 1: 2025-10-01: 1_450 2: diff --git a/policyengine_us/parameters/gov/states/id/dhw/liheap/payment/matrix/electricity.yaml b/policyengine_us/parameters/gov/states/id/dhw/liheap/payment/matrix/electricity.yaml index e072615d616..f94cc043927 100644 --- a/policyengine_us/parameters/gov/states/id/dhw/liheap/payment/matrix/electricity.yaml +++ b/policyengine_us/parameters/gov/states/id/dhw/liheap/payment/matrix/electricity.yaml @@ -2,7 +2,7 @@ description: Idaho provides this base electric-heating benefit by heating area a # Idaho Power & Southern Utilities column, also used as the representative # estimate for an unspecified/unlisted company or an unpublished combination. -# Named Avista and Rocky Mountain Power columns have separate parameters. +# Named northern utilities and Rocky Mountain Power have separate parameters. # Heating areas 1-3 correspond to Areas I-III in the published chart. # Energy-burden groups: 1 = low, 2 = medium, 3 = high. 1: diff --git a/policyengine_us/parameters/gov/states/id/dhw/liheap/payment/matrix/electricity_avista.yaml b/policyengine_us/parameters/gov/states/id/dhw/liheap/payment/matrix/electricity_northern.yaml similarity index 68% rename from policyengine_us/parameters/gov/states/id/dhw/liheap/payment/matrix/electricity_avista.yaml rename to policyengine_us/parameters/gov/states/id/dhw/liheap/payment/matrix/electricity_northern.yaml index 5585891fd61..c1a44cca1f7 100644 --- a/policyengine_us/parameters/gov/states/id/dhw/liheap/payment/matrix/electricity_avista.yaml +++ b/policyengine_us/parameters/gov/states/id/dhw/liheap/payment/matrix/electricity_northern.yaml @@ -1,5 +1,5 @@ # Only published area/provider combinations are stored. -description: Idaho provides this base Avista electric heating benefit by heating area and energy-burden group under the Low Income Home Energy Assistance Program. +description: Idaho provides this base northern electric heating benefit by heating area and energy-burden group under the Low Income Home Energy Assistance Program. 1: 1: '2025-10-01': 322 @@ -18,7 +18,7 @@ metadata: propagate_metadata_to_children: true unit: currency-USD period: year - label: Idaho LIHEAP Avista electric heating benefit + label: Idaho LIHEAP northern electric heating benefit reference: - title: Idaho PY26 LIHEAP Benefit Determination Chart href: https://liheapch.acf.gov/docs/2026/benefits-matricies/ID_BenefitMatrix_Heating_2026.pdf#page=1 diff --git a/policyengine_us/parameters/gov/states/id/dhw/liheap/payment/northern_electric_providers.yaml b/policyengine_us/parameters/gov/states/id/dhw/liheap/payment/northern_electric_providers.yaml new file mode 100644 index 00000000000..4ed3c1e3cf0 --- /dev/null +++ b/policyengine_us/parameters/gov/states/id/dhw/liheap/payment/northern_electric_providers.yaml @@ -0,0 +1,28 @@ +description: Idaho groups these electricity providers in the northern utilities column under the Low Income Home Energy Assistance Program. +# The FY2026 chart names the Avista and Northern Utilities column. Its named +# membership is recovered from Appendix C's historical heating-cost matrix. +# Current state and utility directories confirm these companies' identities, +# while current LIHEAP group membership remains a documented historical proxy. +values: + 2025-10-01: + - AVISTA + - BONNERS_FERRY_LIGHT_AND_WATER + - CLEARWATER_POWER + - IDAHO_COUNTY_LIGHT_AND_POWER + - INLAND_POWER_AND_LIGHT + - KOOTENAI_ELECTRIC + - NORTHERN_LIGHTS + - PLUMMER_ELECTRIC +metadata: + unit: list + period: year + label: Idaho LIHEAP named northern electric utility group + reference: + - title: Idaho FY2026 LIHEAP heating benefit matrix + href: https://liheapch.acf.gov/docs/2026/benefits-matricies/ID_BenefitMatrix_Heating_2026.pdf#page=1 + - title: Historical Idaho LIHEAP Intake Manual, Appendix C, northern utility membership + href: https://web.archive.org/web/20170127123014id_/http://www.healthandwelfare.idaho.gov/Portals/_Rainbow/Manuals/LIHEAP/Appendices/c_htgcost_matrix_PY07.pdf#page=1 + - title: Idaho Office of Energy and Mineral Resources utility directory + href: https://oemr.idaho.gov/utilities/ + - title: Inland Power and Light, northern Idaho service + href: https://www.inlandpower.com/ diff --git a/policyengine_us/tests/policy/baseline/gov/states/id/dhw/liheap/id_liheap.yaml b/policyengine_us/tests/policy/baseline/gov/states/id/dhw/liheap/id_liheap.yaml index 6b20c2993a9..2123cc038ed 100644 --- a/policyengine_us/tests/policy/baseline/gov/states/id/dhw/liheap/id_liheap.yaml +++ b/policyengine_us/tests/policy/baseline/gov/states/id/dhw/liheap/id_liheap.yaml @@ -588,3 +588,40 @@ - 355 - 464 - 173 + +# FY2026 chart's northern electric column and historical Appendix C membership. +# Current OEMR directory and Inland Power's site confirm company identities. +- name: Named northern municipal and cooperative companies use the northern award and cost columns. + period: 2026 + input: + state_code: [ID, ID, ID, ID, ID, ID, ID, ID, ID] + county: [BOUNDARY_COUNTY_ID, NEZ_PERCE_COUNTY_ID, IDAHO_COUNTY_ID, + KOOTENAI_COUNTY_ID, KOOTENAI_COUNTY_ID, BONNER_COUNTY_ID, BENEWAH_COUNTY_ID, + BANNOCK_COUNTY_ID, BANNOCK_COUNTY_ID] + heating_type: [ELECTRICITY, ELECTRICITY, ELECTRICITY, ELECTRICITY, ELECTRICITY, + ELECTRICITY, ELECTRICITY, ELECTRICITY, ELECTRICITY] + electricity_provider: [BONNERS_FERRY_LIGHT_AND_WATER, CLEARWATER_POWER, + IDAHO_COUNTY_LIGHT_AND_POWER, INLAND_POWER_AND_LIGHT, KOOTENAI_ELECTRIC, + NORTHERN_LIGHTS, PLUMMER_ELECTRIC, OTHER, UNSPECIFIED] + id_liheap_countable_income: [4_000, 4_000, 4_000, 4_000, 4_000, 4_000, 4_000, 4_000, 4_000] + id_liheap_income_eligible: [true, true, true, true, true, true, true, true, true] + has_heating_expense: [true, true, true, true, true, true, true, true, true] + output: + id_liheap_estimated_heating_cost: [1_585, 1_450, 1_585, 1_585, 1_585, 1_585, 1_585, 1_455, 1_455] + id_liheap: [402, 348, 402, 402, 402, 402, 402, 410, 410] + +# Northern Lights: 1585/25000 is medium burden, whereas the old representative +# cost of 1455/25000 gives low burden. Both the column and burden must change. +- name: A smaller northern utility changes the burden group as well as the payment column. + period: 2026 + input: + state_code: ID + county: BONNER_COUNTY_ID + heating_type: ELECTRICITY + electricity_provider: NORTHERN_LIGHTS + id_liheap_countable_income: 25_000 + has_heating_expense: true + output: + id_liheap_estimated_heating_cost: 1_585 + id_liheap_income_eligible: true + id_liheap: 387 diff --git a/policyengine_us/variables/gov/states/id/dhw/liheap/id_liheap.py b/policyengine_us/variables/gov/states/id/dhw/liheap/id_liheap.py index 3dc028d36c9..b3db93af858 100644 --- a/policyengine_us/variables/gov/states/id/dhw/liheap/id_liheap.py +++ b/policyengine_us/variables/gov/states/id/dhw/liheap/id_liheap.py @@ -35,16 +35,18 @@ def formula(spm_unit, period, parameters): gas_provider = spm_unit("natural_gas_provider", period) electric_providers = electric_provider.possible_values # The chart leaves Avista Area III and Rocky Mountain Area I blank. - # Retain the representative-column estimate for those combinations, - # unspecified companies and unlisted smaller utilities. - avista_electric = (electric_provider == electric_providers.AVISTA) & (area < 3) + # Retain the representative-column estimate for unpublished area + # combinations, unspecified companies and unlisted smaller utilities. + northern_electric = np.isin( + electric_provider.decode_to_str(), p.northern_electric_providers + ) & (area < 3) rocky_mountain = ( electric_provider == electric_providers.ROCKY_MOUNTAIN_POWER ) & (area > 1) electric_amount = select( - [avista_electric, rocky_mountain], + [northern_electric, rocky_mountain], [ - p.matrix.electricity_avista[min_(area, 2)][burden_group], + p.matrix.electricity_northern[min_(area, 2)][burden_group], p.matrix.electricity_rocky_mountain[max_(area, 2)][burden_group], ], default=p.matrix.electricity[area][burden_group], diff --git a/policyengine_us/variables/gov/states/id/dhw/liheap/id_liheap_estimated_heating_cost.py b/policyengine_us/variables/gov/states/id/dhw/liheap/id_liheap_estimated_heating_cost.py index d90805ae9a9..892c7717bcb 100644 --- a/policyengine_us/variables/gov/states/id/dhw/liheap/id_liheap_estimated_heating_cost.py +++ b/policyengine_us/variables/gov/states/id/dhw/liheap/id_liheap_estimated_heating_cost.py @@ -14,7 +14,8 @@ def formula(spm_unit, period, parameters): area = spm_unit("id_liheap_heating_area", period) heating = spm_unit("heating_type", period) types = heating.possible_values - p = parameters(period).gov.states.id.dhw.liheap.payment.estimated_heating_costs + payment = parameters(period).gov.states.id.dhw.liheap.payment + p = payment.estimated_heating_costs # PY2007 nine-month cost proxy; FY2026 applicability is unconfirmed. # Safe lookup leaves unknown areas unassigned after fuel selection. # No Idaho source names solar or kerosene. As in heating_expense, solar @@ -23,16 +24,19 @@ def formula(spm_unit, period, parameters): electric_provider = spm_unit("electricity_provider", period) gas_provider = spm_unit("natural_gas_provider", period) electric_providers = electric_provider.possible_values + northern_electric = np.isin( + electric_provider.decode_to_str(), payment.northern_electric_providers + ) # As with the payment chart, blank historical combinations retain # the existing representative estimate instead of asserting zero cost. electric_cost = select( [ - (electric_provider == electric_providers.AVISTA) & (area < 3), + northern_electric & (area < 3), (electric_provider == electric_providers.ROCKY_MOUNTAIN_POWER) & (area > 1), ], [ - p.electricity_avista[min_(lookup_area, 2)], + p.electricity_northern[min_(lookup_area, 2)], p.electricity_rocky_mountain[max_(lookup_area, 2)], ], default=p.electricity[lookup_area], From 4336cc12ec47ecaf243f119a45342eab31e6ab25 Mon Sep 17 00:00:00 2001 From: Ziming Date: Fri, 20 Nov 2026 15:13:43 -0500 Subject: [PATCH 5/7] Use Idaho electricity and natural gas provider inputs for LIHEAP columns Replace the shared electricity and natural gas provider inputs with id_liheap_electricity_provider and id_liheap_natural_gas_provider, enums in the Idaho LIHEAP folder that list only the companies the Idaho heating matrix distinguishes. The matrix and estimated-cost formulas read them. Co-Authored-By: Claude Fable 5.2 --- .../liheap-utility-provider-inputs.added.md | 1 - .../gov/states/id/dhw/liheap/id_liheap.yaml | 16 +++---- .../gov/states/id/dhw/liheap/id_liheap.py | 4 +- .../liheap/id_liheap_electricity_provider.py | 40 ++++++++++++++++ .../id_liheap_estimated_heating_cost.py | 4 +- .../liheap/id_liheap_natural_gas_provider.py | 30 ++++++++++++ .../expense/utilities/electricity_provider.py | 48 ------------------- .../expense/utilities/natural_gas_provider.py | 37 -------------- 8 files changed, 82 insertions(+), 98 deletions(-) delete mode 100644 changelog.d/liheap-utility-provider-inputs.added.md create mode 100644 policyengine_us/variables/gov/states/id/dhw/liheap/id_liheap_electricity_provider.py create mode 100644 policyengine_us/variables/gov/states/id/dhw/liheap/id_liheap_natural_gas_provider.py delete mode 100644 policyengine_us/variables/household/expense/utilities/electricity_provider.py delete mode 100644 policyengine_us/variables/household/expense/utilities/natural_gas_provider.py diff --git a/changelog.d/liheap-utility-provider-inputs.added.md b/changelog.d/liheap-utility-provider-inputs.added.md deleted file mode 100644 index 5ef51d5f975..00000000000 --- a/changelog.d/liheap-utility-provider-inputs.added.md +++ /dev/null @@ -1 +0,0 @@ -Add shared electricity and natural gas provider inputs for utility-dependent benefit rules. diff --git a/policyengine_us/tests/policy/baseline/gov/states/id/dhw/liheap/id_liheap.yaml b/policyengine_us/tests/policy/baseline/gov/states/id/dhw/liheap/id_liheap.yaml index 2123cc038ed..c510a7bb6a0 100644 --- a/policyengine_us/tests/policy/baseline/gov/states/id/dhw/liheap/id_liheap.yaml +++ b/policyengine_us/tests/policy/baseline/gov/states/id/dhw/liheap/id_liheap.yaml @@ -349,7 +349,7 @@ - ELECTRICITY - ELECTRICITY - ELECTRICITY - electricity_provider: + id_liheap_electricity_provider: - AVISTA - AVISTA - AVISTA @@ -411,7 +411,7 @@ - ELECTRICITY - ELECTRICITY - ELECTRICITY - electricity_provider: + id_liheap_electricity_provider: - ROCKY_MOUNTAIN_POWER - ROCKY_MOUNTAIN_POWER - ROCKY_MOUNTAIN_POWER @@ -473,7 +473,7 @@ - NATURAL_GAS - NATURAL_GAS - NATURAL_GAS - natural_gas_provider: + id_liheap_natural_gas_provider: - AVISTA - AVISTA - AVISTA @@ -523,7 +523,7 @@ heating_type: - ELECTRICITY - ELECTRICITY - electricity_provider: + id_liheap_electricity_provider: - IDAHO_POWER - AVISTA id_liheap_countable_income: @@ -559,11 +559,11 @@ - ELECTRICITY - ELECTRICITY - NATURAL_GAS - electricity_provider: + id_liheap_electricity_provider: - ROCKY_MOUNTAIN_POWER - AVISTA - UNSPECIFIED - natural_gas_provider: + id_liheap_natural_gas_provider: - UNSPECIFIED - UNSPECIFIED - AVISTA @@ -600,7 +600,7 @@ BANNOCK_COUNTY_ID, BANNOCK_COUNTY_ID] heating_type: [ELECTRICITY, ELECTRICITY, ELECTRICITY, ELECTRICITY, ELECTRICITY, ELECTRICITY, ELECTRICITY, ELECTRICITY, ELECTRICITY] - electricity_provider: [BONNERS_FERRY_LIGHT_AND_WATER, CLEARWATER_POWER, + id_liheap_electricity_provider: [BONNERS_FERRY_LIGHT_AND_WATER, CLEARWATER_POWER, IDAHO_COUNTY_LIGHT_AND_POWER, INLAND_POWER_AND_LIGHT, KOOTENAI_ELECTRIC, NORTHERN_LIGHTS, PLUMMER_ELECTRIC, OTHER, UNSPECIFIED] id_liheap_countable_income: [4_000, 4_000, 4_000, 4_000, 4_000, 4_000, 4_000, 4_000, 4_000] @@ -618,7 +618,7 @@ state_code: ID county: BONNER_COUNTY_ID heating_type: ELECTRICITY - electricity_provider: NORTHERN_LIGHTS + id_liheap_electricity_provider: NORTHERN_LIGHTS id_liheap_countable_income: 25_000 has_heating_expense: true output: diff --git a/policyengine_us/variables/gov/states/id/dhw/liheap/id_liheap.py b/policyengine_us/variables/gov/states/id/dhw/liheap/id_liheap.py index b3db93af858..44e143b0300 100644 --- a/policyengine_us/variables/gov/states/id/dhw/liheap/id_liheap.py +++ b/policyengine_us/variables/gov/states/id/dhw/liheap/id_liheap.py @@ -31,8 +31,8 @@ def formula(spm_unit, period, parameters): area = clip(spm_unit("id_liheap_heating_area", period), 1, 3) heating = spm_unit("heating_type", period) types = heating.possible_values - electric_provider = spm_unit("electricity_provider", period) - gas_provider = spm_unit("natural_gas_provider", period) + electric_provider = spm_unit("id_liheap_electricity_provider", period) + gas_provider = spm_unit("id_liheap_natural_gas_provider", period) electric_providers = electric_provider.possible_values # The chart leaves Avista Area III and Rocky Mountain Area I blank. # Retain the representative-column estimate for unpublished area diff --git a/policyengine_us/variables/gov/states/id/dhw/liheap/id_liheap_electricity_provider.py b/policyengine_us/variables/gov/states/id/dhw/liheap/id_liheap_electricity_provider.py new file mode 100644 index 00000000000..bbe7a5a006b --- /dev/null +++ b/policyengine_us/variables/gov/states/id/dhw/liheap/id_liheap_electricity_provider.py @@ -0,0 +1,40 @@ +from policyengine_us.model_api import * + + +class IDLIHEAPElectricityProvider(Enum): + IDAHO_POWER = "Idaho Power" + AVISTA = "Avista" + BONNERS_FERRY_LIGHT_AND_WATER = "Bonners Ferry Light and Water" + CLEARWATER_POWER = "Clearwater Power" + IDAHO_COUNTY_LIGHT_AND_POWER = "Idaho County Light and Power" + INLAND_POWER_AND_LIGHT = "Inland Power and Light" + KOOTENAI_ELECTRIC = "Kootenai Electric Cooperative" + NORTHERN_LIGHTS = "Northern Lights Incorporated" + PLUMMER_ELECTRIC = "Plummer Electric Department" + ROCKY_MOUNTAIN_POWER = "Rocky Mountain Power" + OTHER = "Other electricity provider" + UNSPECIFIED = "Unspecified" + + +class id_liheap_electricity_provider(Variable): + value_type = Enum + entity = SPMUnit + possible_values = IDLIHEAPElectricityProvider + default_value = IDLIHEAPElectricityProvider.UNSPECIFIED + definition_period = YEAR + label = "Idaho LIHEAP electricity provider" + documentation = ( + "Company providing the home's electric service, as named on the " + "electric bill. It selects the electric column of the Idaho LIHEAP " + "heating matrix and estimated heating costs: Idaho Power and southern " + "utilities, Avista and northern utilities, or Rocky Mountain Power. " + "OTHER means a reported company outside the listed choices and " + "UNSPECIFIED (the default) means the company was not reported; both " + "use the Idaho Power and southern utilities column." + ) + defined_for = StateCode.ID + reference = ( + "https://liheapch.acf.gov/docs/2026/benefits-matricies/ID_BenefitMatrix_Heating_2026.pdf#page=1", + "https://web.archive.org/web/20170127123014id_/http://www.healthandwelfare.idaho.gov/Portals/_Rainbow/Manuals/LIHEAP/Appendices/c_htgcost_matrix_PY07.pdf#page=1", + "https://oemr.idaho.gov/utilities/", + ) diff --git a/policyengine_us/variables/gov/states/id/dhw/liheap/id_liheap_estimated_heating_cost.py b/policyengine_us/variables/gov/states/id/dhw/liheap/id_liheap_estimated_heating_cost.py index 892c7717bcb..907dc032191 100644 --- a/policyengine_us/variables/gov/states/id/dhw/liheap/id_liheap_estimated_heating_cost.py +++ b/policyengine_us/variables/gov/states/id/dhw/liheap/id_liheap_estimated_heating_cost.py @@ -21,8 +21,8 @@ def formula(spm_unit, period, parameters): # No Idaho source names solar or kerosene. As in heating_expense, solar # reads as electric and kerosene as the chart's oil. lookup_area = clip(area, 1, 3) - electric_provider = spm_unit("electricity_provider", period) - gas_provider = spm_unit("natural_gas_provider", period) + electric_provider = spm_unit("id_liheap_electricity_provider", period) + gas_provider = spm_unit("id_liheap_natural_gas_provider", period) electric_providers = electric_provider.possible_values northern_electric = np.isin( electric_provider.decode_to_str(), payment.northern_electric_providers diff --git a/policyengine_us/variables/gov/states/id/dhw/liheap/id_liheap_natural_gas_provider.py b/policyengine_us/variables/gov/states/id/dhw/liheap/id_liheap_natural_gas_provider.py new file mode 100644 index 00000000000..01edd6aade6 --- /dev/null +++ b/policyengine_us/variables/gov/states/id/dhw/liheap/id_liheap_natural_gas_provider.py @@ -0,0 +1,30 @@ +from policyengine_us.model_api import * + + +class IDLIHEAPNaturalGasProvider(Enum): + INTERMOUNTAIN_GAS = "Intermountain Gas" + AVISTA = "Avista" + OTHER = "Other natural gas provider" + UNSPECIFIED = "Unspecified" + + +class id_liheap_natural_gas_provider(Variable): + value_type = Enum + entity = SPMUnit + possible_values = IDLIHEAPNaturalGasProvider + default_value = IDLIHEAPNaturalGasProvider.UNSPECIFIED + definition_period = YEAR + label = "Idaho LIHEAP natural gas provider" + documentation = ( + "Company providing the home's natural gas service, as named on the " + "gas bill. It selects the Intermountain Gas or Avista column of the " + "Idaho LIHEAP heating matrix and estimated heating costs. OTHER means " + "a reported company outside the listed choices and UNSPECIFIED (the " + "default) means the company was not reported; both use the " + "Intermountain Gas column." + ) + defined_for = StateCode.ID + reference = ( + "https://liheapch.acf.gov/docs/2026/benefits-matricies/ID_BenefitMatrix_Heating_2026.pdf#page=1", + "https://web.archive.org/web/20170127123014id_/http://www.healthandwelfare.idaho.gov/Portals/_Rainbow/Manuals/LIHEAP/Appendices/c_htgcost_matrix_PY07.pdf#page=1", + ) diff --git a/policyengine_us/variables/household/expense/utilities/electricity_provider.py b/policyengine_us/variables/household/expense/utilities/electricity_provider.py deleted file mode 100644 index e4f4592056a..00000000000 --- a/policyengine_us/variables/household/expense/utilities/electricity_provider.py +++ /dev/null @@ -1,48 +0,0 @@ -from policyengine_us.model_api import * - - -class ElectricityProvider(Enum): - UNSPECIFIED = "Unspecified" - AMEREN_ILLINOIS = "Ameren Illinois" - AVISTA = "Avista" - BLOCK_ISLAND_UTILITY_DISTRICT = "Block Island Utility District" - BONNERS_FERRY_LIGHT_AND_WATER = "Bonners Ferry Light and Water" - CLEAR_RIVER_ELECTRIC_AND_WATER_DISTRICT = ( - "Clear River Electric and Water District (formerly Pascoag)" - ) - CLEARWATER_POWER = "Clearwater Power" - COMED = "ComEd" - IDAHO_COUNTY_LIGHT_AND_POWER = "Idaho County Light and Power" - IDAHO_POWER = "Idaho Power" - INLAND_POWER_AND_LIGHT = "Inland Power and Light" - KOOTENAI_ELECTRIC = "Kootenai Electric Cooperative" - NORTHERN_LIGHTS = "Northern Lights Incorporated" - PLUMMER_ELECTRIC = "Plummer Electric Department" - RHODE_ISLAND_ENERGY = "Rhode Island Energy (Narragansett Electric)" - ROCKY_MOUNTAIN_POWER = "Rocky Mountain Power" - OTHER = "Other electricity provider" - - -class electricity_provider(Variable): - value_type = Enum - possible_values = ElectricityProvider - default_value = ElectricityProvider.UNSPECIFIED - entity = SPMUnit - definition_period = YEAR - label = "Electricity utility provider" - documentation = ( - "Company providing the home's electric distribution service, as named on " - "the utility bill. Report the distribution utility even when a separate " - "retailer supplies the energy. UNSPECIFIED means the company was not " - "reported; OTHER means a reported company outside the listed choices. " - "The choices initially cover named utilities needed for Idaho, Illinois " - "and Rhode Island heating assistance and can be extended for other " - "programs. This input does not imply program enrollment or bill receipt." - ) - reference = ( - "https://liheapch.acf.gov/docs/2026/benefits-matricies/ID_BenefitMatrix_Heating_2026.pdf#page=1", - "https://dceo.illinois.gov/communityservices/utilitybillassistance/howtoapply.html", - "https://webserver.rilegislature.gov/Statutes/TITLE39/39-1/39-1-27.12.htm", - "https://oemr.idaho.gov/utilities/", - "https://www.inlandpower.com/", - ) diff --git a/policyengine_us/variables/household/expense/utilities/natural_gas_provider.py b/policyengine_us/variables/household/expense/utilities/natural_gas_provider.py deleted file mode 100644 index 348a15a3d34..00000000000 --- a/policyengine_us/variables/household/expense/utilities/natural_gas_provider.py +++ /dev/null @@ -1,37 +0,0 @@ -from policyengine_us.model_api import * - - -class NaturalGasProvider(Enum): - UNSPECIFIED = "Unspecified" - AMEREN_ILLINOIS = "Ameren Illinois" - AVISTA = "Avista" - INTERMOUNTAIN_GAS = "Intermountain Gas" - NICOR_GAS = "Nicor Gas" - NORTH_SHORE_GAS = "North Shore Gas" - PEOPLES_GAS = "Peoples Gas" - RHODE_ISLAND_ENERGY = "Rhode Island Energy (Narragansett Electric)" - OTHER = "Other natural gas provider" - - -class natural_gas_provider(Variable): - value_type = Enum - possible_values = NaturalGasProvider - default_value = NaturalGasProvider.UNSPECIFIED - entity = SPMUnit - definition_period = YEAR - label = "Natural gas utility provider" - documentation = ( - "Company providing the home's natural gas distribution service, as named " - "on the utility bill. Report the distribution utility even when a " - "separate retailer supplies the gas. UNSPECIFIED means the company was " - "not reported; OTHER means a reported company outside the listed choices. " - "The choices initially cover named utilities needed for Idaho, Illinois " - "and Rhode Island heating assistance and can be extended for other " - "programs. Electricity and gas companies are reported independently. " - "This input does not imply program enrollment or bill receipt." - ) - reference = ( - "https://liheapch.acf.gov/docs/2026/benefits-matricies/ID_BenefitMatrix_Heating_2026.pdf#page=1", - "https://dceo.illinois.gov/communityservices/utilitybillassistance/howtoapply.html", - "https://webserver.rilegislature.gov/Statutes/TITLE39/39-1/39-1-27.12.htm", - ) From aa10001d21a3b01835250919ee95dee24bc0ab80 Mon Sep 17 00:00:00 2001 From: Ziming Date: Fri, 20 Nov 2026 15:26:40 -0500 Subject: [PATCH 6/7] Move provider input notes from documentation fields to comments Co-Authored-By: Claude Fable 5.2 --- .../dhw/liheap/id_liheap_electricity_provider.py | 15 ++++++--------- .../dhw/liheap/id_liheap_natural_gas_provider.py | 13 +++++-------- 2 files changed, 11 insertions(+), 17 deletions(-) diff --git a/policyengine_us/variables/gov/states/id/dhw/liheap/id_liheap_electricity_provider.py b/policyengine_us/variables/gov/states/id/dhw/liheap/id_liheap_electricity_provider.py index bbe7a5a006b..d16187f9937 100644 --- a/policyengine_us/variables/gov/states/id/dhw/liheap/id_liheap_electricity_provider.py +++ b/policyengine_us/variables/gov/states/id/dhw/liheap/id_liheap_electricity_provider.py @@ -2,6 +2,10 @@ class IDLIHEAPElectricityProvider(Enum): + # The electric company named on the bill. It selects the electric column + # of the heating matrix and the estimated heating costs: Idaho Power and + # southern utilities, Avista and northern utilities, or Rocky Mountain + # Power. IDAHO_POWER = "Idaho Power" AVISTA = "Avista" BONNERS_FERRY_LIGHT_AND_WATER = "Bonners Ferry Light and Water" @@ -12,6 +16,8 @@ class IDLIHEAPElectricityProvider(Enum): NORTHERN_LIGHTS = "Northern Lights Incorporated" PLUMMER_ELECTRIC = "Plummer Electric Department" ROCKY_MOUNTAIN_POWER = "Rocky Mountain Power" + # A reported company outside the listed choices, or a company that was + # not reported. Both use the Idaho Power and southern utilities column. OTHER = "Other electricity provider" UNSPECIFIED = "Unspecified" @@ -23,15 +29,6 @@ class id_liheap_electricity_provider(Variable): default_value = IDLIHEAPElectricityProvider.UNSPECIFIED definition_period = YEAR label = "Idaho LIHEAP electricity provider" - documentation = ( - "Company providing the home's electric service, as named on the " - "electric bill. It selects the electric column of the Idaho LIHEAP " - "heating matrix and estimated heating costs: Idaho Power and southern " - "utilities, Avista and northern utilities, or Rocky Mountain Power. " - "OTHER means a reported company outside the listed choices and " - "UNSPECIFIED (the default) means the company was not reported; both " - "use the Idaho Power and southern utilities column." - ) defined_for = StateCode.ID reference = ( "https://liheapch.acf.gov/docs/2026/benefits-matricies/ID_BenefitMatrix_Heating_2026.pdf#page=1", diff --git a/policyengine_us/variables/gov/states/id/dhw/liheap/id_liheap_natural_gas_provider.py b/policyengine_us/variables/gov/states/id/dhw/liheap/id_liheap_natural_gas_provider.py index 01edd6aade6..6c61b01ad05 100644 --- a/policyengine_us/variables/gov/states/id/dhw/liheap/id_liheap_natural_gas_provider.py +++ b/policyengine_us/variables/gov/states/id/dhw/liheap/id_liheap_natural_gas_provider.py @@ -2,8 +2,13 @@ class IDLIHEAPNaturalGasProvider(Enum): + # The natural gas company named on the bill. It selects the Intermountain + # Gas or Avista column of the heating matrix and the estimated heating + # costs. INTERMOUNTAIN_GAS = "Intermountain Gas" AVISTA = "Avista" + # A reported company outside the listed choices, or a company that was + # not reported. Both use the Intermountain Gas column. OTHER = "Other natural gas provider" UNSPECIFIED = "Unspecified" @@ -15,14 +20,6 @@ class id_liheap_natural_gas_provider(Variable): default_value = IDLIHEAPNaturalGasProvider.UNSPECIFIED definition_period = YEAR label = "Idaho LIHEAP natural gas provider" - documentation = ( - "Company providing the home's natural gas service, as named on the " - "gas bill. It selects the Intermountain Gas or Avista column of the " - "Idaho LIHEAP heating matrix and estimated heating costs. OTHER means " - "a reported company outside the listed choices and UNSPECIFIED (the " - "default) means the company was not reported; both use the " - "Intermountain Gas column." - ) defined_for = StateCode.ID reference = ( "https://liheapch.acf.gov/docs/2026/benefits-matricies/ID_BenefitMatrix_Heating_2026.pdf#page=1", From b52e200b8931c63d505a3939c9de9c1218e3639b Mon Sep 17 00:00:00 2001 From: Ziming Date: Sat, 21 Nov 2026 19:21:38 -0500 Subject: [PATCH 7/7] Match Idaho LIHEAP provider matrices to sibling files and extend provider tests - Three provider matrix files: bare date keys, key comments and `breakdown` metadata whose ranges match the stored areas. No value changes. - northern_electric_providers: state why Lamb Creek Trailer Park is omitted and use one title for the chart PDF. estimated_heating_costs names the "Utah Power & Light" column. - Tests: id_liheap Cases 15-22 use counties each utility serves, drop a duplicate case and add the Intermountain, OTHER and unreported gas choices; id_liheap_estimated_heating_cost Case 6 covers the six provider cost cells. Co-Authored-By: Claude Fable 5.2 --- .../payment/estimated_heating_costs.yaml | 4 +- .../payment/matrix/electricity_northern.yaml | 28 +- .../matrix/electricity_rocky_mountain.yaml | 28 +- .../payment/matrix/natural_gas_avista.yaml | 28 +- .../payment/northern_electric_providers.yaml | 6 +- .../gov/states/id/dhw/liheap/id_liheap.yaml | 409 ++++++------------ .../id_liheap_estimated_heating_cost.yaml | 41 +- 7 files changed, 243 insertions(+), 301 deletions(-) diff --git a/policyengine_us/parameters/gov/states/id/dhw/liheap/payment/estimated_heating_costs.yaml b/policyengine_us/parameters/gov/states/id/dhw/liheap/payment/estimated_heating_costs.yaml index d7ef1faea08..acbed0339b1 100644 --- a/policyengine_us/parameters/gov/states/id/dhw/liheap/payment/estimated_heating_costs.yaml +++ b/policyengine_us/parameters/gov/states/id/dhw/liheap/payment/estimated_heating_costs.yaml @@ -7,7 +7,9 @@ description: Idaho uses these estimated heating-season costs by fuel and heating # Unspecified/unlisted providers use Idaho Power & Southern Utilities for # electricity and the complete Intermountain Gas column for natural gas. # Named northern utilities and Rocky Mountain Power use their historical -# provider columns. Northern membership follows northern_electric_providers. +# provider columns. The Rocky Mountain Power costs come from the Appendix C +# column headed "Utah Power & Light". Northern membership follows +# northern_electric_providers. # The old rent-cost column and old benefit percentages are not used. oil_or_propane: 1: diff --git a/policyengine_us/parameters/gov/states/id/dhw/liheap/payment/matrix/electricity_northern.yaml b/policyengine_us/parameters/gov/states/id/dhw/liheap/payment/matrix/electricity_northern.yaml index c1a44cca1f7..59679333308 100644 --- a/policyengine_us/parameters/gov/states/id/dhw/liheap/payment/matrix/electricity_northern.yaml +++ b/policyengine_us/parameters/gov/states/id/dhw/liheap/payment/matrix/electricity_northern.yaml @@ -1,24 +1,34 @@ -# Only published area/provider combinations are stored. description: Idaho provides this base northern electric heating benefit by heating area and energy-burden group under the Low Income Home Energy Assistance Program. + +# Only published area/provider combinations are stored. +# Heating areas 1-2 correspond to Areas I-II in the published chart. +# Energy-burden groups: 1 = low, 2 = medium, 3 = high. 1: 1: - '2025-10-01': 322 + 2025-10-01: 322 2: - '2025-10-01': 335 + 2025-10-01: 335 3: - '2025-10-01': 348 + 2025-10-01: 348 2: 1: - '2025-10-01': 371 + 2025-10-01: 371 2: - '2025-10-01': 387 + 2025-10-01: 387 3: - '2025-10-01': 402 + 2025-10-01: 402 + metadata: propagate_metadata_to_children: true unit: currency-USD period: year label: Idaho LIHEAP northern electric heating benefit + breakdown: + - range(1, 3) + - range(1, 4) + breakdown_labels: + - Heating area + - Energy-burden group reference: - - title: Idaho PY26 LIHEAP Benefit Determination Chart - href: https://liheapch.acf.gov/docs/2026/benefits-matricies/ID_BenefitMatrix_Heating_2026.pdf#page=1 + - title: Idaho PY26 LIHEAP Benefit Determination Chart + href: https://liheapch.acf.gov/docs/2026/benefits-matricies/ID_BenefitMatrix_Heating_2026.pdf#page=1 diff --git a/policyengine_us/parameters/gov/states/id/dhw/liheap/payment/matrix/electricity_rocky_mountain.yaml b/policyengine_us/parameters/gov/states/id/dhw/liheap/payment/matrix/electricity_rocky_mountain.yaml index f613f960f95..6388c7035bb 100644 --- a/policyengine_us/parameters/gov/states/id/dhw/liheap/payment/matrix/electricity_rocky_mountain.yaml +++ b/policyengine_us/parameters/gov/states/id/dhw/liheap/payment/matrix/electricity_rocky_mountain.yaml @@ -1,24 +1,34 @@ -# Only published area/provider combinations are stored. description: Idaho provides this base Rocky Mountain Power electric heating benefit by heating area and energy-burden group under the Low Income Home Energy Assistance Program. + +# Only published area/provider combinations are stored. +# Heating areas 2-3 correspond to Areas II-III in the published chart. +# Energy-burden groups: 1 = low, 2 = medium, 3 = high. 2: 1: - '2025-10-01': 407 + 2025-10-01: 407 2: - '2025-10-01': 424 + 2025-10-01: 424 3: - '2025-10-01': 441 + 2025-10-01: 441 3: 1: - '2025-10-01': 461 + 2025-10-01: 461 2: - '2025-10-01': 481 + 2025-10-01: 481 3: - '2025-10-01': 500 + 2025-10-01: 500 + metadata: propagate_metadata_to_children: true unit: currency-USD period: year label: Idaho LIHEAP Rocky Mountain Power electric heating benefit + breakdown: + - range(2, 4) + - range(1, 4) + breakdown_labels: + - Heating area + - Energy-burden group reference: - - title: Idaho PY26 LIHEAP Benefit Determination Chart - href: https://liheapch.acf.gov/docs/2026/benefits-matricies/ID_BenefitMatrix_Heating_2026.pdf#page=1 + - title: Idaho PY26 LIHEAP Benefit Determination Chart + href: https://liheapch.acf.gov/docs/2026/benefits-matricies/ID_BenefitMatrix_Heating_2026.pdf#page=1 diff --git a/policyengine_us/parameters/gov/states/id/dhw/liheap/payment/matrix/natural_gas_avista.yaml b/policyengine_us/parameters/gov/states/id/dhw/liheap/payment/matrix/natural_gas_avista.yaml index 51764660ea9..4f19c298fac 100644 --- a/policyengine_us/parameters/gov/states/id/dhw/liheap/payment/matrix/natural_gas_avista.yaml +++ b/policyengine_us/parameters/gov/states/id/dhw/liheap/payment/matrix/natural_gas_avista.yaml @@ -1,24 +1,34 @@ -# Only published area/provider combinations are stored. description: Idaho provides this base Avista natural gas heating benefit by heating area and energy-burden group under the Low Income Home Energy Assistance Program. + +# Only published area/provider combinations are stored. +# Heating areas 1-2 correspond to Areas I-II in the published chart. +# Energy-burden groups: 1 = low, 2 = medium, 3 = high. 1: 1: - '2025-10-01': 168 + 2025-10-01: 168 2: - '2025-10-01': 176 + 2025-10-01: 176 3: - '2025-10-01': 183 + 2025-10-01: 183 2: 1: - '2025-10-01': 194 + 2025-10-01: 194 2: - '2025-10-01': 203 + 2025-10-01: 203 3: - '2025-10-01': 211 + 2025-10-01: 211 + metadata: propagate_metadata_to_children: true unit: currency-USD period: year label: Idaho LIHEAP Avista natural gas heating benefit + breakdown: + - range(1, 3) + - range(1, 4) + breakdown_labels: + - Heating area + - Energy-burden group reference: - - title: Idaho PY26 LIHEAP Benefit Determination Chart - href: https://liheapch.acf.gov/docs/2026/benefits-matricies/ID_BenefitMatrix_Heating_2026.pdf#page=1 + - title: Idaho PY26 LIHEAP Benefit Determination Chart + href: https://liheapch.acf.gov/docs/2026/benefits-matricies/ID_BenefitMatrix_Heating_2026.pdf#page=1 diff --git a/policyengine_us/parameters/gov/states/id/dhw/liheap/payment/northern_electric_providers.yaml b/policyengine_us/parameters/gov/states/id/dhw/liheap/payment/northern_electric_providers.yaml index 4ed3c1e3cf0..b7096160597 100644 --- a/policyengine_us/parameters/gov/states/id/dhw/liheap/payment/northern_electric_providers.yaml +++ b/policyengine_us/parameters/gov/states/id/dhw/liheap/payment/northern_electric_providers.yaml @@ -3,6 +3,9 @@ description: Idaho groups these electricity providers in the northern utilities # membership is recovered from Appendix C's historical heating-cost matrix. # Current state and utility directories confirm these companies' identities, # while current LIHEAP group membership remains a documented historical proxy. +# The Appendix C footnote also names Lamb Creek Trailer Park. It is left out +# because its current utility identity was not established, so such a +# household reports OTHER and uses the Idaho Power & Southern Utilities column. values: 2025-10-01: - AVISTA @@ -13,12 +16,13 @@ values: - KOOTENAI_ELECTRIC - NORTHERN_LIGHTS - PLUMMER_ELECTRIC + metadata: unit: list period: year label: Idaho LIHEAP named northern electric utility group reference: - - title: Idaho FY2026 LIHEAP heating benefit matrix + - title: Idaho PY26 LIHEAP Benefit Determination Chart href: https://liheapch.acf.gov/docs/2026/benefits-matricies/ID_BenefitMatrix_Heating_2026.pdf#page=1 - title: Historical Idaho LIHEAP Intake Manual, Appendix C, northern utility membership href: https://web.archive.org/web/20170127123014id_/http://www.healthandwelfare.idaho.gov/Portals/_Rainbow/Manuals/LIHEAP/Appendices/c_htgcost_matrix_PY07.pdf#page=1 diff --git a/policyengine_us/tests/policy/baseline/gov/states/id/dhw/liheap/id_liheap.yaml b/policyengine_us/tests/policy/baseline/gov/states/id/dhw/liheap/id_liheap.yaml index c510a7bb6a0..5c8f2703cbb 100644 --- a/policyengine_us/tests/policy/baseline/gov/states/id/dhw/liheap/id_liheap.yaml +++ b/policyengine_us/tests/policy/baseline/gov/states/id/dhw/liheap/id_liheap.yaml @@ -324,304 +324,173 @@ id_liheap_countable_income: 12_564 id_liheap: 367 -# FY2026 chart, provider columns; low/medium/high using PY2007 costs. -- name: Named Avista electric provider selects each published burden and area cell. +- name: Case 15, named Avista electric provider selects each published burden and area cell. period: 2026 + absolute_error_margin: 0.01 + # FY2026 chart, Avista and Northern Utilities column, with the PY2007 northern electric costs. + # Nez Perce County is Area I (cost 1_450) and Kootenai County Area II (cost 1_585). + # Income 40_000 is low (3.63%, 3.96%), 20_000 medium (7.25%, 7.93%), 4_000 high (36.25%, 39.63%). input: - state_code: - - ID - - ID - - ID - - ID - - ID - - ID - county: - - ADA_COUNTY_ID - - ADA_COUNTY_ID - - ADA_COUNTY_ID - - BANNOCK_COUNTY_ID - - BANNOCK_COUNTY_ID - - BANNOCK_COUNTY_ID - heating_type: - - ELECTRICITY - - ELECTRICITY - - ELECTRICITY - - ELECTRICITY - - ELECTRICITY - - ELECTRICITY - id_liheap_electricity_provider: - - AVISTA - - AVISTA - - AVISTA - - AVISTA - - AVISTA - - AVISTA - id_liheap_countable_income: - - 40000 - - 20000 - - 4000 - - 40000 - - 20000 - - 4000 - id_liheap_income_eligible: - - true - - true - - true - - true - - true - - true - has_heating_expense: - - true - - true - - true - - true - - true - - true + state_code: [ID, ID, ID, ID, ID, ID] + county: [NEZ_PERCE_COUNTY_ID, NEZ_PERCE_COUNTY_ID, NEZ_PERCE_COUNTY_ID, + KOOTENAI_COUNTY_ID, KOOTENAI_COUNTY_ID, KOOTENAI_COUNTY_ID] + heating_type: [ELECTRICITY, ELECTRICITY, ELECTRICITY, + ELECTRICITY, ELECTRICITY, ELECTRICITY] + id_liheap_electricity_provider: [AVISTA, AVISTA, AVISTA, + AVISTA, AVISTA, AVISTA] + id_liheap_countable_income: [40_000, 20_000, 4_000, + 40_000, 20_000, 4_000] + id_liheap_income_eligible: [true, true, true, true, true, true] + has_heating_expense: [true, true, true, true, true, true] output: - id_liheap: - - 322 - - 335 - - 348 - - 371 - - 387 - - 402 + id_liheap: [322, 335, 348, + 371, 387, 402] -# FY2026 chart, provider columns; low/medium/high using PY2007 costs. -- name: Named Rocky Mountain Power electric provider selects each published burden and area cell. +- name: Case 16, named Rocky Mountain Power electric provider selects each published burden and area cell. period: 2026 + absolute_error_margin: 0.01 + # FY2026 chart, Rocky Mountain Power column, with the PY2007 costs from the Utah Power & Light column. + # Franklin County is Area II (cost 1_692) and Bear Lake County Area III (cost 1_836). + # Income 40_000 is low (4.23%, 4.59%), 20_000 medium (8.46%, 9.18%), 4_000 high (42.3%, 45.9%). input: - state_code: - - ID - - ID - - ID - - ID - - ID - - ID - county: - - BANNOCK_COUNTY_ID - - BANNOCK_COUNTY_ID - - BANNOCK_COUNTY_ID - - BEAR_LAKE_COUNTY_ID - - BEAR_LAKE_COUNTY_ID - - BEAR_LAKE_COUNTY_ID - heating_type: - - ELECTRICITY - - ELECTRICITY - - ELECTRICITY - - ELECTRICITY - - ELECTRICITY - - ELECTRICITY - id_liheap_electricity_provider: - - ROCKY_MOUNTAIN_POWER - - ROCKY_MOUNTAIN_POWER - - ROCKY_MOUNTAIN_POWER - - ROCKY_MOUNTAIN_POWER - - ROCKY_MOUNTAIN_POWER - - ROCKY_MOUNTAIN_POWER - id_liheap_countable_income: - - 40000 - - 20000 - - 4000 - - 40000 - - 20000 - - 4000 - id_liheap_income_eligible: - - true - - true - - true - - true - - true - - true - has_heating_expense: - - true - - true - - true - - true - - true - - true + state_code: [ID, ID, ID, ID, ID, ID] + county: [FRANKLIN_COUNTY_ID, FRANKLIN_COUNTY_ID, FRANKLIN_COUNTY_ID, + BEAR_LAKE_COUNTY_ID, BEAR_LAKE_COUNTY_ID, BEAR_LAKE_COUNTY_ID] + heating_type: [ELECTRICITY, ELECTRICITY, ELECTRICITY, + ELECTRICITY, ELECTRICITY, ELECTRICITY] + id_liheap_electricity_provider: [ROCKY_MOUNTAIN_POWER, ROCKY_MOUNTAIN_POWER, ROCKY_MOUNTAIN_POWER, + ROCKY_MOUNTAIN_POWER, ROCKY_MOUNTAIN_POWER, ROCKY_MOUNTAIN_POWER] + id_liheap_countable_income: [40_000, 20_000, 4_000, + 40_000, 20_000, 4_000] + id_liheap_income_eligible: [true, true, true, true, true, true] + has_heating_expense: [true, true, true, true, true, true] output: - id_liheap: - - 407 - - 424 - - 441 - - 461 - - 481 - - 500 + id_liheap: [407, 424, 441, + 461, 481, 500] -# FY2026 chart, provider columns; low/medium/high using PY2007 costs. -- name: Named Avista gas provider selects each published burden and area cell. +- name: Case 17, named Avista gas provider selects each published burden and area cell. period: 2026 + absolute_error_margin: 0.01 + # FY2026 chart, Avista gas column, with the PY2007 Avista gas costs. + # Nez Perce County is Area I (cost 875) and Kootenai County Area II (cost 1_200). + # Income 40_000 is low (2.19%, 3%), 14_000 medium (6.25%, 8.57%), 4_000 high (21.88%, 30%). input: - state_code: - - ID - - ID - - ID - - ID - - ID - - ID - county: - - ADA_COUNTY_ID - - ADA_COUNTY_ID - - ADA_COUNTY_ID - - BANNOCK_COUNTY_ID - - BANNOCK_COUNTY_ID - - BANNOCK_COUNTY_ID - heating_type: - - NATURAL_GAS - - NATURAL_GAS - - NATURAL_GAS - - NATURAL_GAS - - NATURAL_GAS - - NATURAL_GAS - id_liheap_natural_gas_provider: - - AVISTA - - AVISTA - - AVISTA - - AVISTA - - AVISTA - - AVISTA - id_liheap_countable_income: - - 40000 - - 14000 - - 4000 - - 40000 - - 14000 - - 4000 - id_liheap_income_eligible: - - true - - true - - true - - true - - true - - true - has_heating_expense: - - true - - true - - true - - true - - true - - true + state_code: [ID, ID, ID, ID, ID, ID] + county: [NEZ_PERCE_COUNTY_ID, NEZ_PERCE_COUNTY_ID, NEZ_PERCE_COUNTY_ID, + KOOTENAI_COUNTY_ID, KOOTENAI_COUNTY_ID, KOOTENAI_COUNTY_ID] + heating_type: [NATURAL_GAS, NATURAL_GAS, NATURAL_GAS, + NATURAL_GAS, NATURAL_GAS, NATURAL_GAS] + id_liheap_natural_gas_provider: [AVISTA, AVISTA, AVISTA, + AVISTA, AVISTA, AVISTA] + id_liheap_countable_income: [40_000, 14_000, 4_000, + 40_000, 14_000, 4_000] + id_liheap_income_eligible: [true, true, true, true, true, true] + has_heating_expense: [true, true, true, true, true, true] output: - id_liheap: - - 168 - - 176 - - 183 - - 194 - - 203 - - 211 + id_liheap: [168, 176, 183, + 194, 203, 211] -# 1335/24000 < 6%, whereas 1450/24000 >= 6%. -- name: Provider-specific cost changes the burden group before the benefit lookup. +- name: Case 18, provider-specific cost changes the burden group before the benefit lookup. period: 2026 + absolute_error_margin: 0.01 + # Area I at income 24_000. Idaho Power in Ada County: 1_335 / 24_000 = 5.56% is low, 328. + # Avista in Nez Perce County: 1_450 / 24_000 = 6.04% is medium, 335. input: - state_code: - - ID - - ID - county: - - ADA_COUNTY_ID - - ADA_COUNTY_ID - heating_type: - - ELECTRICITY - - ELECTRICITY - id_liheap_electricity_provider: - - IDAHO_POWER - - AVISTA - id_liheap_countable_income: - - 24000 - - 24000 - id_liheap_income_eligible: - - true - - true - has_heating_expense: - - true - - true + state_code: [ID, ID] + county: [ADA_COUNTY_ID, NEZ_PERCE_COUNTY_ID] + heating_type: [ELECTRICITY, ELECTRICITY] + id_liheap_electricity_provider: [IDAHO_POWER, AVISTA] + id_liheap_countable_income: [24_000, 24_000] + id_liheap_income_eligible: [true, true] + has_heating_expense: [true, true] output: - id_liheap_estimated_heating_cost: - - 1335 - - 1450 - id_liheap: - - 328 - - 335 + id_liheap_estimated_heating_cost: [1_335, 1_450] + id_liheap: [328, 335] -# These are fallback estimates, not published awards for the blank cells. -- name: Unpublished provider area combinations retain the documented representative estimate. +- name: Case 19, unpublished provider area combinations retain the documented representative estimate. period: 2026 + absolute_error_margin: 0.01 + # The chart prints no amount for Rocky Mountain Power in Area I or for Avista in Area III. + # These rows pay the Idaho Power or Intermountain Gas column as a fallback estimate, not a published award. + # Income 4_000 is high. Ada electric 1_335 pays 355; Bear Lake electric 1_605 pays 464; Bear Lake gas 1_207 pays 173. input: - state_code: - - ID - - ID - - ID - county: - - ADA_COUNTY_ID - - BEAR_LAKE_COUNTY_ID - - BEAR_LAKE_COUNTY_ID - heating_type: - - ELECTRICITY - - ELECTRICITY - - NATURAL_GAS - id_liheap_electricity_provider: - - ROCKY_MOUNTAIN_POWER - - AVISTA - - UNSPECIFIED - id_liheap_natural_gas_provider: - - UNSPECIFIED - - UNSPECIFIED - - AVISTA - id_liheap_countable_income: - - 4000 - - 4000 - - 4000 - id_liheap_income_eligible: - - true - - true - - true - has_heating_expense: - - true - - true - - true + state_code: [ID, ID, ID] + county: [ADA_COUNTY_ID, BEAR_LAKE_COUNTY_ID, BEAR_LAKE_COUNTY_ID] + heating_type: [ELECTRICITY, ELECTRICITY, NATURAL_GAS] + id_liheap_electricity_provider: [ROCKY_MOUNTAIN_POWER, AVISTA, UNSPECIFIED] + id_liheap_natural_gas_provider: [UNSPECIFIED, UNSPECIFIED, AVISTA] + id_liheap_countable_income: [4_000, 4_000, 4_000] + id_liheap_income_eligible: [true, true, true] + has_heating_expense: [true, true, true] output: - id_liheap_estimated_heating_cost: - - 1335 - - 1605 - - 1207 - id_liheap: - - 355 - - 464 - - 173 + id_liheap_estimated_heating_cost: [1_335, 1_605, 1_207] + id_liheap: [355, 464, 173] -# FY2026 chart's northern electric column and historical Appendix C membership. -# Current OEMR directory and Inland Power's site confirm company identities. -- name: Named northern municipal and cooperative companies use the northern award and cost columns. +- name: Case 20, named northern municipal and cooperative companies use the northern award and cost columns. period: 2026 + absolute_error_margin: 0.01 + # FY2026 chart's northern electric column with the historical Appendix C membership. + # The current OEMR directory and Inland Power's site confirm the company identities. + # Income 4_000 is high. Northern cost 1_585 pays 402 in Area II; Nez Perce County is Area I, 1_450 and 348. + # Other and unspecified companies in Bannock County keep the Idaho Power cost 1_455 and 410. input: state_code: [ID, ID, ID, ID, ID, ID, ID, ID, ID] county: [BOUNDARY_COUNTY_ID, NEZ_PERCE_COUNTY_ID, IDAHO_COUNTY_ID, - KOOTENAI_COUNTY_ID, KOOTENAI_COUNTY_ID, BONNER_COUNTY_ID, BENEWAH_COUNTY_ID, - BANNOCK_COUNTY_ID, BANNOCK_COUNTY_ID] - heating_type: [ELECTRICITY, ELECTRICITY, ELECTRICITY, ELECTRICITY, ELECTRICITY, - ELECTRICITY, ELECTRICITY, ELECTRICITY, ELECTRICITY] - id_liheap_electricity_provider: [BONNERS_FERRY_LIGHT_AND_WATER, CLEARWATER_POWER, - IDAHO_COUNTY_LIGHT_AND_POWER, INLAND_POWER_AND_LIGHT, KOOTENAI_ELECTRIC, - NORTHERN_LIGHTS, PLUMMER_ELECTRIC, OTHER, UNSPECIFIED] - id_liheap_countable_income: [4_000, 4_000, 4_000, 4_000, 4_000, 4_000, 4_000, 4_000, 4_000] + KOOTENAI_COUNTY_ID, KOOTENAI_COUNTY_ID, BONNER_COUNTY_ID, + BENEWAH_COUNTY_ID, BANNOCK_COUNTY_ID, BANNOCK_COUNTY_ID] + heating_type: [ELECTRICITY, ELECTRICITY, ELECTRICITY, + ELECTRICITY, ELECTRICITY, ELECTRICITY, + ELECTRICITY, ELECTRICITY, ELECTRICITY] + id_liheap_electricity_provider: [BONNERS_FERRY_LIGHT_AND_WATER, CLEARWATER_POWER, IDAHO_COUNTY_LIGHT_AND_POWER, + INLAND_POWER_AND_LIGHT, KOOTENAI_ELECTRIC, NORTHERN_LIGHTS, + PLUMMER_ELECTRIC, OTHER, UNSPECIFIED] + id_liheap_countable_income: [4_000, 4_000, 4_000, + 4_000, 4_000, 4_000, + 4_000, 4_000, 4_000] id_liheap_income_eligible: [true, true, true, true, true, true, true, true, true] has_heating_expense: [true, true, true, true, true, true, true, true, true] output: - id_liheap_estimated_heating_cost: [1_585, 1_450, 1_585, 1_585, 1_585, 1_585, 1_585, 1_455, 1_455] - id_liheap: [402, 348, 402, 402, 402, 402, 402, 410, 410] + id_liheap_estimated_heating_cost: [1_585, 1_450, 1_585, + 1_585, 1_585, 1_585, + 1_585, 1_455, 1_455] + id_liheap: [402, 348, 402, + 402, 402, 402, + 402, 410, 410] + +- name: Case 21, Intermountain Gas and an unlisted gas company pay the Intermountain Gas column. + period: 2026 + absolute_error_margin: 0.01 + # Income 12_000 is medium. Intermountain Gas in Ada County (Area I): 977 / 12_000 = 8.14%, 127. + # An unlisted gas company in Franklin County (Area II): 1_100 / 12_000 = 9.17%, 147. + # The Avista gas column would cost 875 and 1_200 and pay 176 and 203. + input: + state_code: [ID, ID] + county: [ADA_COUNTY_ID, FRANKLIN_COUNTY_ID] + heating_type: [NATURAL_GAS, NATURAL_GAS] + id_liheap_natural_gas_provider: [INTERMOUNTAIN_GAS, OTHER] + id_liheap_countable_income: [12_000, 12_000] + id_liheap_income_eligible: [true, true] + has_heating_expense: [true, true] + output: + id_liheap_estimated_heating_cost: [977, 1_100] + id_liheap: [127, 147] -# Northern Lights: 1585/25000 is medium burden, whereas the old representative -# cost of 1455/25000 gives low burden. Both the column and burden must change. -- name: A smaller northern utility changes the burden group as well as the payment column. +- name: Case 22, the gas company alone selects the gas column of a gas-heated household with Avista electricity. period: 2026 + absolute_error_margin: 0.01 + # Nez Perce County is Area I. Both households buy electricity from Avista and heat with gas; income 4_000 is high. + # Avista gas: 875 / 4_000 = 21.88%, 183. Unreported gas company: Intermountain Gas column, 977 / 4_000 = 24.4%, 132. + # The electric company does not reach the gas branch: it does not pay the northern electric column + # (cost 1_450, 348) and does not select the Avista gas column in the second row. input: - state_code: ID - county: BONNER_COUNTY_ID - heating_type: ELECTRICITY - id_liheap_electricity_provider: NORTHERN_LIGHTS - id_liheap_countable_income: 25_000 - has_heating_expense: true + state_code: [ID, ID] + county: [NEZ_PERCE_COUNTY_ID, NEZ_PERCE_COUNTY_ID] + heating_type: [NATURAL_GAS, NATURAL_GAS] + id_liheap_electricity_provider: [AVISTA, AVISTA] + id_liheap_natural_gas_provider: [AVISTA, UNSPECIFIED] + id_liheap_countable_income: [4_000, 4_000] + id_liheap_income_eligible: [true, true] + has_heating_expense: [true, true] output: - id_liheap_estimated_heating_cost: 1_585 - id_liheap_income_eligible: true - id_liheap: 387 + id_liheap_estimated_heating_cost: [875, 977] + id_liheap: [183, 132] diff --git a/policyengine_us/tests/policy/baseline/gov/states/id/dhw/liheap/id_liheap_estimated_heating_cost.yaml b/policyengine_us/tests/policy/baseline/gov/states/id/dhw/liheap/id_liheap_estimated_heating_cost.yaml index a71cdf164e0..0ddf2a7b81b 100644 --- a/policyengine_us/tests/policy/baseline/gov/states/id/dhw/liheap/id_liheap_estimated_heating_cost.yaml +++ b/policyengine_us/tests/policy/baseline/gov/states/id/dhw/liheap/id_liheap_estimated_heating_cost.yaml @@ -2,8 +2,14 @@ # https://web.archive.org/web/20170127123014id_/http://www.healthandwelfare.idaho.gov/Portals/_Rainbow/Manuals/LIHEAP/Appendices/c_htgcost_matrix_PY07.pdf#page=1 # PY2007 estimated nine-month costs are used as a modeling assumption; # their current FY2026 applicability is unconfirmed. No inflation or 12/9 scaling. -# Electricity uses Idaho Power & Southern Utilities. Natural gas uses the -# Intermountain column as a modeling simplification, without a provider input. +# The electricity and natural gas provider inputs select the cost column. +# Electricity: Avista and the named northern utilities use the Northern +# Utilities column in Areas I and II (1_450, 1_585). Rocky Mountain Power uses +# the Utah Power & Light column in Areas II and III (1_692, 1_836). Any other +# or unreported company, and a named company outside those areas, uses +# Idaho Power & Southern Utilities. +# Natural gas: Avista uses its own column in Areas I and II (875, 1_200). Any +# other or unreported company, and Avista in Area III, uses Intermountain. - name: Case 1, six supported fuels use the historical costs in all three areas. period: 2026 @@ -72,3 +78,34 @@ heating_type: [SOLAR, KEROSENE] output: id_liheap_estimated_heating_cost: [1_335, 1_625] + +- name: Case 6, named providers use their own cost columns and an unstored company and area pair falls back. + period: 2026 + absolute_error_margin: 0.01 + # Avista electric: Nez Perce County (Area I) 1_450, Kootenai County (Area II) 1_585. + # Rocky Mountain Power: Franklin County (Area II) 1_692, Bear Lake County (Area III) 1_836. + # Avista gas: Nez Perce County 875, Kootenai County 1_200. + # Rocky Mountain Power has no stored Area I cost, so Ada County keeps the Idaho Power 1_335. + input: + state_code: [ID, ID, ID, ID, ID, ID, ID] + county: [NEZ_PERCE_COUNTY_ID, KOOTENAI_COUNTY_ID, + FRANKLIN_COUNTY_ID, BEAR_LAKE_COUNTY_ID, + NEZ_PERCE_COUNTY_ID, KOOTENAI_COUNTY_ID, + ADA_COUNTY_ID] + heating_type: [ELECTRICITY, ELECTRICITY, + ELECTRICITY, ELECTRICITY, + NATURAL_GAS, NATURAL_GAS, + ELECTRICITY] + id_liheap_electricity_provider: [AVISTA, AVISTA, + ROCKY_MOUNTAIN_POWER, ROCKY_MOUNTAIN_POWER, + UNSPECIFIED, UNSPECIFIED, + ROCKY_MOUNTAIN_POWER] + id_liheap_natural_gas_provider: [UNSPECIFIED, UNSPECIFIED, + UNSPECIFIED, UNSPECIFIED, + AVISTA, AVISTA, + UNSPECIFIED] + output: + id_liheap_estimated_heating_cost: [1_450, 1_585, + 1_692, 1_836, + 875, 1_200, + 1_335]