diff --git a/changelog_entry.yaml b/changelog_entry.yaml index e69de29bb2d..9bcccf34797 100644 --- a/changelog_entry.yaml +++ b/changelog_entry.yaml @@ -0,0 +1,4 @@ +- bump: minor + changes: + added: + - New Jersey TANF income eligibility. diff --git a/policyengine_us/tests/policy/baseline/gov/states/nj/njdhs/tanf/nj_tanf_income_eligible.yaml b/policyengine_us/tests/policy/baseline/gov/states/nj/njdhs/tanf/nj_tanf_income_eligible.yaml new file mode 100644 index 00000000000..fe03996a410 --- /dev/null +++ b/policyengine_us/tests/policy/baseline/gov/states/nj/njdhs/tanf/nj_tanf_income_eligible.yaml @@ -0,0 +1,54 @@ +- name: Household with no income is eligible. (0+0<1) + period: 2023 + input: + state_code: NJ + nj_tanf_maximum_allowable_income: 1 + nj_tanf_countable_earned_income: 0 + nj_tanf_countable_gross_unearned_income: 0 + output: + nj_tanf_income_eligible: true + + +- name: Household with income exceeding maximum allowable income is ineligible. (1+1>1) + period: 2023 + input: + state_code: NJ + nj_tanf_maximum_allowable_income: 1 + nj_tanf_countable_earned_income: 1 + nj_tanf_countable_gross_unearned_income: 1 + output: + nj_tanf_income_eligible: false + + +- name: Household with income equals maximum allowable income is eligible. (1+0=1) + period: 2023 + input: + state_code: NJ + nj_tanf_maximum_allowable_income: 1 + nj_tanf_countable_earned_income: 1 + nj_tanf_countable_gross_unearned_income: 0 + output: + nj_tanf_income_eligible: true + +- name: Household with income equals maximum allowable income and income equals maximum benefit is ineligible. + period: 2023 + input: + state_code: NJ + nj_tanf_maximum_allowable_income: 1 + nj_tanf_maximum_benefit: 1 + nj_tanf_countable_earned_income: 1 + nj_tanf_countable_gross_unearned_income: 0 + output: + nj_tanf_income_eligible: false + + +- name: Household with income less than maximum allowable income and income less than maximum benefit is eligible. + period: 2023 + input: + state_code: NJ + nj_tanf_maximum_allowable_income: 3 + nj_tanf_maximum_benefit: 2 + nj_tanf_countable_earned_income: 1 + nj_tanf_countable_gross_unearned_income: 0 + output: + nj_tanf_income_eligible: true diff --git a/policyengine_us/variables/gov/states/nj/njdhs/tanf/nj_tanf_income_eligible.py b/policyengine_us/variables/gov/states/nj/njdhs/tanf/nj_tanf_income_eligible.py new file mode 100644 index 00000000000..c7d2c7230a1 --- /dev/null +++ b/policyengine_us/variables/gov/states/nj/njdhs/tanf/nj_tanf_income_eligible.py @@ -0,0 +1,27 @@ +from policyengine_us.model_api import * + + +class nj_tanf_income_eligible(Variable): + value_type = bool + entity = SPMUnit + label = "New Jersey TANF income eligible" + definition_period = YEAR + defined_for = StateCode.NJ + + def formula(spm_unit, period, parameters): + income = add( + spm_unit, + period, + [ + "nj_tanf_countable_earned_income", + "nj_tanf_countable_gross_unearned_income", + ], + ) + maximum_allowable_income = spm_unit( + "nj_tanf_maximum_allowable_income", period + ) + maximum_benefit = spm_unit("nj_tanf_maximum_benefit", period) + # New Jersey Administrative Code 10:90-3.1 + return (income <= maximum_allowable_income) & ( + income < maximum_benefit + )