diff --git a/changelog.d/liheap-eligible.added.md b/changelog.d/liheap-eligible.added.md new file mode 100644 index 00000000000..35e232e3c4a --- /dev/null +++ b/changelog.d/liheap-eligible.added.md @@ -0,0 +1 @@ +Add `liheap_eligible`, a national output that is true when a household is eligible for its state's regular LIHEAP heating or cooling benefit, and `ak_hap_eligible` for Alaska. diff --git a/policyengine_us/parameters/gov/hhs/liheap/regular_eligibility.yaml b/policyengine_us/parameters/gov/hhs/liheap/regular_eligibility.yaml new file mode 100644 index 00000000000..8b8b79a8316 --- /dev/null +++ b/policyengine_us/parameters/gov/hhs/liheap/regular_eligibility.yaml @@ -0,0 +1,76 @@ +description: States determine eligibility for regular payments under the Low Income Home Energy Assistance Program with these variables. +values: + 2023-01-01: + # Alaska's award applies every eligibility condition, so the flag follows it. + - ak_hap_eligible # Alaska Heating Assistance Program + - al_liheap_eligible # Alabama LIHEAP + - al_liheap_cooling_eligible # Alabama LIHEAP cooling + - ar_liheap_eligible # Arkansas LIHEAP + - ar_liheap_cooling_eligible # Arkansas LIHEAP cooling + - az_liheap_eligible # Arizona LIHEAP + # Each of California's three components requires this common eligibility. + - ca_liheap_basic_eligible # California LIHEAP + - co_leap_eligible # Colorado LEAP + - ct_ceap_eligible # Connecticut CEAP + - dc_liheap_eligible # DC LIHEAP + - de_liheap_eligible # Delaware LIHEAP + # Delaware's cooling benefit has no fixed amount, so no payment is listed. + - de_liheap_cooling_eligible # Delaware LIHEAP cooling + - fl_liheap_eligible # Florida LIHEAP + - ga_liheap_eligible # Georgia LIHEAP + - ga_liheap_cooling_eligible # Georgia LIHEAP cooling + - hi_liheap_eligible # Hawaii LIHEAP + - ia_liheap_eligible # Iowa LIHEAP + - id_liheap_eligible # Idaho LIHEAP + - il_liheap_eligible # Illinois LIHEAP, without crisis assistance + - in_eap_eligible # Indiana EAP + - ks_liheap_eligible # Kansas LIEAP + - ky_liheap_eligible # Kentucky LIHEAP + - ky_liheap_cooling_eligible # Kentucky LIHEAP cooling + - la_liheap_eligible # Louisiana LIHEAP + - la_liheap_cooling_eligible # Louisiana LIHEAP cooling + - ma_liheap_eligible # Massachusetts LIHEAP + - md_meap_eligible # Maryland MEAP + - me_heap_eligible # Maine HEAP + - mn_eap_eligible # Minnesota EAP + - mo_liheap_eligible # Missouri LIHEAP + - ms_liheap_eligible # Mississippi LIHEAP + - mt_liheap_eligible # Montana LIHEAP + - nc_lieap_eligible # North Carolina LIEAP + - nd_liheap_eligible # North Dakota LIHEAP + - ne_liheap_eligible # Nebraska LIHEAP + - ne_liheap_cooling_eligible # Nebraska LIHEAP cooling + - nh_fap_eligible # New Hampshire FAP + - nj_liheap_eligible # New Jersey LIHEAP + - nj_liheap_cooling_eligible # New Jersey LIHEAP cooling + - nm_liheap_eligible # New Mexico LIHEAP + - nv_liheap_eligible # Nevada LIHEAP + - ny_heap_eligible # New York HEAP + - oh_liheap_eligible # Ohio HEAP + - ok_liheap_eligible # Oklahoma LIHEAP + - ok_liheap_cooling_eligible # Oklahoma LIHEAP cooling + - or_liheap_eligible # Oregon LIHEAP + - pa_liheap_eligible # Pennsylvania LIHEAP + - ri_liheap_eligible # Rhode Island LIHEAP + - sc_liheap_eligible # South Carolina LIHEAP + - sc_liheap_cooling_eligible # South Carolina LIHEAP cooling + - sd_liheap_eligible # South Dakota LIEAP + - tn_liheap_eligible # Tennessee LIHEAP + - tx_ceap_eligible # Texas CEAP + - ut_heat_eligible # Utah HEAT + - va_eap_eligible # Virginia EAP + - va_eap_cooling_eligible # Virginia EAP cooling + - vt_liheap_eligible # Vermont Seasonal Fuel Assistance + - wa_liheap_eligible # Washington LIHEAP + - wi_wheap_eligible # Wisconsin WHEAP + # West Virginia's only eligibility output is its income test. + - wv_lieap_income_eligible # West Virginia LIEAP + - wy_lieap_eligible # Wyoming LIEAP + +metadata: + unit: list + period: year + label: LIHEAP regular state eligibility + reference: + - title: 42 U.S.C. 8624(b)(2) + href: https://www.law.cornell.edu/uscode/text/42/8624#b_2 diff --git a/policyengine_us/tests/policy/baseline/gov/hhs/liheap/liheap_eligible.yaml b/policyengine_us/tests/policy/baseline/gov/hhs/liheap/liheap_eligible.yaml new file mode 100644 index 00000000000..024bd192991 --- /dev/null +++ b/policyengine_us/tests/policy/baseline/gov/hhs/liheap/liheap_eligible.yaml @@ -0,0 +1,89 @@ +# The national flag is true when any state eligibility variable listed in +# gov.hhs.liheap.regular_eligibility is true. 2026 poverty guidelines +# (contiguous US): 15,960 for one person plus 5,680 for each additional person. + +- name: Case 1, a household eligible for its state's program is eligible. + period: 2026 + input: + people: + person1: + age: 34 + # 12 an hour for 30 hours a week: 12 * 30 * 52 = 18,720. + employment_income_before_lsr: 18_720 + spm_units: + spm_unit: + members: [person1] + heating_type: ELECTRICITY + has_cooling_expense: true + # 165 a month for heating and air conditioning. + pre_subsidy_electricity_expense: 1_980 + households: + household: + members: [person1] + state_code: TX + output: + # 18,720 / 15,960 = 117% of the guideline, within Texas's 150%. + tx_ceap_eligible: true + liheap_eligible: true + +- name: Case 2, a household over its state's income limit is not eligible. + period: 2026 + input: + people: + person1: + age: 34 + # 15 an hour full time: 15 * 40 * 52 = 31,200. + employment_income_before_lsr: 31_200 + spm_units: + spm_unit: + members: [person1] + heating_type: ELECTRICITY + has_cooling_expense: true + # 165 a month for heating and air conditioning. + pre_subsidy_electricity_expense: 1_980 + households: + household: + members: [person1] + state_code: TX + output: + # 31,200 / 15,960 = 195% of the guideline, over Texas's 150%. + tx_ceap_eligible: false + liheap_eligible: false + +- name: Case 3, cooling eligibility alone makes a household eligible, with no payment where the state sets no amount. + period: 2027 + absolute_error_margin: 0.01 + input: + state_code: DE + de_liheap_eligible: false + de_liheap_cooling_eligible: true + output: + # Delaware pays cooling bills up to a maximum, with no fixed amount, so + # the national total has nothing to add. + liheap: 0 + liheap_eligible: true + +- name: Case 4, Michigan's Home Heating Credit is not in the flag. + period: 2027 + input: + people: + person1: + age: 41 + # Part-time wages. + employment_income_before_lsr: 9_000 + spm_units: + spm_unit: + members: [person1] + heating_type: NATURAL_GAS + has_cooling_expense: true + # 85 a month for gas heat. + gas_expense: 1_020 + households: + household: + members: [person1] + state_code: MI + output: + # Michigan's regular heating help is a refundable tax credit, which the + # list leaves out, and Michigan has no regular cooling payment. + mi_standard_home_heating_credit_eligible: true + liheap_eligible: false diff --git a/policyengine_us/tests/policy/baseline/gov/states/ak/dpa/hap/ak_hap_eligible.yaml b/policyengine_us/tests/policy/baseline/gov/states/ak/dpa/hap/ak_hap_eligible.yaml new file mode 100644 index 00000000000..a5dc78e78b1 --- /dev/null +++ b/policyengine_us/tests/policy/baseline/gov/states/ak/dpa/hap/ak_hap_eligible.yaml @@ -0,0 +1,77 @@ +# A household is eligible when it has an award. The award applies every +# condition of 7 AAC 44, including the 2.0-point minimum of 44.080(m) after +# the dwelling share (h) and the utility-allowance reduction (l). +# Sources, each URL listed once: +# Regulation 7 AAC 44.035-44.080: +# https://www.akleg.gov/basis/aac.asp?media=print&secStart=7.44.010&secEnd=7.44.9001 +# Grant manual 3004-5 steps 1-8 and FY2027 price of $175 per point: +# http://dpaweb.hss.state.ak.us/manuals/HAP/3004/3004-5_grant_computation.htm +# Community table, Fairbanks oil 10, Juneau oil 5: +# http://dpaweb.hss.state.ak.us/manuals/HAP/addendum/addendum_a.htm + +# Fairbanks oil 10 * two-bedroom house 1 * income factor 1 = 10 points, plus +# 1 for age 65 = 11; 11 * 175 = 1,925. +- name: Case 1, a household with an award is eligible. + period: 2027 + absolute_error_margin: 0.01 + input: + people: + person1: + age: 65 + immigration_status: CITIZEN + ssi: 0 + ak_ssp: 0 + ak_permanent_fund_dividend: 0 + spm_units: + spm_unit1: + members: [person1] + heating_type: FUEL_OIL + ak_hap_dwelling_type: TWO_BEDROOM_HOUSE + fuel_oil_expense: 1_000 + ak_atap: 0 + receives_housing_assistance: false + heat_expense_included_in_rent: false + households: + household1: + members: [person1] + state_code: AK + place_fips: '24230' + output: + ak_hap: 1_925 + ak_hap_eligible: true + liheap_eligible: true + +# Juneau oil 5 * dwelling 1 * income factor .6 = 3 points, so the base award +# is 3 * 175 = 525. This subsidized household pays its heat directly, so +# 44.080(l) halves the points to 1.5, below the 2.0 minimum of (m). +- name: Case 2, a household below the minimum after the utility-allowance reduction is not eligible. + period: 2027 + absolute_error_margin: 0.01 + input: + people: + person1: + age: 40 + immigration_status: CITIZEN + employment_income: 24_000 + ssi: 0 + ak_ssp: 0 + ak_permanent_fund_dividend: 0 + spm_units: + spm_unit1: + members: [person1] + heating_type: FUEL_OIL + ak_hap_dwelling_type: TWO_BEDROOM_HOUSE + fuel_oil_expense: 300 + ak_atap: 0 + receives_housing_assistance: true + heat_expense_included_in_rent: false + households: + household1: + members: [person1] + state_code: AK + place_fips: '36400' + output: + ak_hap_base_benefit: 525 + ak_hap: 0 + ak_hap_eligible: false + liheap_eligible: false diff --git a/policyengine_us/tests/test_aggregate_list_integrity.py b/policyengine_us/tests/test_aggregate_list_integrity.py index cd9016cb651..85132490b27 100644 --- a/policyengine_us/tests/test_aggregate_list_integrity.py +++ b/policyengine_us/tests/test_aggregate_list_integrity.py @@ -37,6 +37,7 @@ "gov/states/household/state_cdccs.yaml", "gov/hhs/ccdf/child_care_subsidy_programs.yaml", "gov/hhs/liheap/regular_payments.yaml", + "gov/hhs/liheap/regular_eligibility.yaml", "gov/household/household_state_benefits.yaml", "gov/states/household/state_property_tax_refunds.yaml", ] @@ -234,6 +235,44 @@ def test_liheap_total_sums_every_registered_state_payment(variables): ) +LIHEAP_ELIGIBILITY = "gov/hhs/liheap/regular_eligibility.yaml" + +# Eligibility flags of listed payments whose defined_for is not the flag. +LIHEAP_ELIGIBILITY_FLAGS = { + # Alaska's flag is derived from its award. + "ak_hap": "ak_hap_eligible", + # These payments are gated by state and read the flag in the formula. + "al_liheap": "al_liheap_eligible", + "fl_liheap": "fl_liheap_eligible", + "ok_liheap": "ok_liheap_eligible", + # California's components each require its common household eligibility. + "ca_liheap_utility_heating": "ca_liheap_basic_eligible", + "ca_liheap_covered_liquid_heating": "ca_liheap_basic_eligible", +} + + +def test_liheap_eligibility_lists_the_flag_of_every_listed_payment(variables): + """A payment in the national total must have its flag in the eligibility list. + + `liheap_eligible` is true when any listed state flag is true. Each payment + `liheap` sums is gated by an eligibility flag, usually its defined_for. + That flag belongs in the eligibility list, so a new state or cooling + payment cannot reach the total while its households read as ineligible. + """ + listed = members_of(LIHEAP_ELIGIBILITY) + missing = sorted( + payment + for payment in members_of(LIHEAP_PAYMENTS) + if LIHEAP_ELIGIBILITY_FLAGS.get(payment, variables[payment].defined_for) + not in listed + ) + assert not missing, ( + f"{LIHEAP_ELIGIBILITY} lacks the eligibility flag of these payments " + f"in {LIHEAP_PAYMENTS}: {missing}. Add each flag to the list, or name " + "it in LIHEAP_ELIGIBILITY_FLAGS in this test." + ) + + # --- Reform-side copies of the benefit aggregates ------------------------- AGGREGATE_VARIABLES = ("household_benefits", "spm_unit_benefits") diff --git a/policyengine_us/variables/gov/hhs/liheap/liheap_eligible.py b/policyengine_us/variables/gov/hhs/liheap/liheap_eligible.py new file mode 100644 index 00000000000..e189d6e8d59 --- /dev/null +++ b/policyengine_us/variables/gov/hhs/liheap/liheap_eligible.py @@ -0,0 +1,20 @@ +from policyengine_us.model_api import * + + +class liheap_eligible(Variable): + value_type = bool + entity = SPMUnit + definition_period = YEAR + label = "Eligible for regular LIHEAP heating or cooling assistance" + documentation = ( + "Whether the household is eligible for its state's regular LIHEAP " + "heating or cooling benefit. heating_type is a required input: most " + "states' heating eligibility is false while it is unset. An eligible " + "household can have a liheap payment of zero, for example when the " + "state's benefit table has no amount for its fuel, or under " + "Delaware's cooling benefit, which has no fixed amount. Leaves out " + "Michigan's Home Heating Credit, and crisis, weatherization and " + "equipment assistance." + ) + reference = "https://www.law.cornell.edu/uscode/text/42/8624#b_2" + adds = "gov.hhs.liheap.regular_eligibility" diff --git a/policyengine_us/variables/gov/states/ak/dpa/hap/ak_hap_eligible.py b/policyengine_us/variables/gov/states/ak/dpa/hap/ak_hap_eligible.py new file mode 100644 index 00000000000..66ea0455edb --- /dev/null +++ b/policyengine_us/variables/gov/states/ak/dpa/hap/ak_hap_eligible.py @@ -0,0 +1,20 @@ +from policyengine_us.model_api import * + + +class ak_hap_eligible(Variable): + value_type = bool + entity = SPMUnit + definition_period = YEAR + label = "Eligible for the Alaska Heating Assistance Program" + reference = ( + "http://dpaweb.hss.state.ak.us/manuals/HAP/3004/3004-5_grant_computation.htm", + "https://www.akleg.gov/basis/aac.asp?media=print&secStart=7.44.010&secEnd=7.44.9001", + ) + defined_for = StateCode.AK + + def formula(spm_unit, period, parameters): + # The award applies every eligibility condition of 7 AAC 44, including + # the 2.0-point minimum of 44.080(m), which is tested after the + # dwelling share (h) and the utility-allowance reduction (l). So a + # household is eligible exactly when it has an award. + return spm_unit("ak_hap", period) > 0