From 1f2ca7917cfe75aa4b342a227ea97b0ff5f42e78 Mon Sep 17 00:00:00 2001 From: mitchellpound Date: Thu, 8 Jun 2023 09:50:07 -0600 Subject: [PATCH 01/19] Created backbone structure for LA income tax logic --- .../la/tax/income/agi/la_total_additions.py | 19 ++++++++++ .../tax/income/agi/la_total_subtractions.py | 14 ++++++++ .../gov/states/la/tax/income/la_income_tax.py | 17 +++++++++ .../income/la_income_tax_before_credits.py | 36 +++++++++++++++++++ ...la_income_tax_before_refundable_credits.py | 19 ++++++++++ .../states/la/tax/income/la_taxable_income.py | 28 +++++++++++++++ 6 files changed, 133 insertions(+) create mode 100644 fiscalsim_us/variables/gov/states/la/tax/income/agi/la_total_additions.py create mode 100644 fiscalsim_us/variables/gov/states/la/tax/income/agi/la_total_subtractions.py create mode 100644 fiscalsim_us/variables/gov/states/la/tax/income/la_income_tax.py create mode 100644 fiscalsim_us/variables/gov/states/la/tax/income/la_income_tax_before_credits.py create mode 100644 fiscalsim_us/variables/gov/states/la/tax/income/la_income_tax_before_refundable_credits.py create mode 100644 fiscalsim_us/variables/gov/states/la/tax/income/la_taxable_income.py diff --git a/fiscalsim_us/variables/gov/states/la/tax/income/agi/la_total_additions.py b/fiscalsim_us/variables/gov/states/la/tax/income/agi/la_total_additions.py new file mode 100644 index 000000000..d7577682e --- /dev/null +++ b/fiscalsim_us/variables/gov/states/la/tax/income/agi/la_total_additions.py @@ -0,0 +1,19 @@ +from fiscalsim_us.model_api import * + + +class la_total_additions(Variable): + """ + Additions to Louisiana adjusted income + Lines 2A-D on Form IT-540 Schedule E. These additions include + * Interest and dividend income from other states and their political subdivisions + * Recapture of START contributions + * Recapture of START K12 contributions + * Add back of pass-through entity + """ + + value_type = float + entity = TaxUnit + label = "Louisiana total additions to AGI" + unit = USD + definition_period = YEAR + defined_for = StateCode.LA diff --git a/fiscalsim_us/variables/gov/states/la/tax/income/agi/la_total_subtractions.py b/fiscalsim_us/variables/gov/states/la/tax/income/agi/la_total_subtractions.py new file mode 100644 index 000000000..aa8704620 --- /dev/null +++ b/fiscalsim_us/variables/gov/states/la/tax/income/agi/la_total_subtractions.py @@ -0,0 +1,14 @@ +from fiscalsim_us.model_api import * + + +class la_total_additions(Variable): + """ + subtractions from louisiana adjusted income + """ + + value_type = float + entity = TaxUnit + label = "Louisiana total subtractions from AGI" + unit = USD + definition_period = YEAR + defined_for = StateCode.LA diff --git a/fiscalsim_us/variables/gov/states/la/tax/income/la_income_tax.py b/fiscalsim_us/variables/gov/states/la/tax/income/la_income_tax.py new file mode 100644 index 000000000..63edfda8c --- /dev/null +++ b/fiscalsim_us/variables/gov/states/la/tax/income/la_income_tax.py @@ -0,0 +1,17 @@ +from fiscalsim_us.model_api import * + + +class la_income_tax(Variable): + value_type = float + entity = TaxUnit + label = "Louisiana income tax" + unit = USD + definition_period = YEAR + reference = ( + "https://revenue.louisiana.gov/TaxForms/IT540WEB(2022)%20F%20D2.pdf", + "https://revenue.louisiana.gov/TaxForms/IT540iWEB(2022)D1.pdf", + ) + defined_for = StateCode.LA + adds = ["la_income_tax_before_refundable_credits"] + subtracts = ["la_refundable_credits"] + diff --git a/fiscalsim_us/variables/gov/states/la/tax/income/la_income_tax_before_credits.py b/fiscalsim_us/variables/gov/states/la/tax/income/la_income_tax_before_credits.py new file mode 100644 index 000000000..6a99b854c --- /dev/null +++ b/fiscalsim_us/variables/gov/states/la/tax/income/la_income_tax_before_credits.py @@ -0,0 +1,36 @@ +from fiscalsim_us.model_api import * + + +class la_income_tax_before_credits(Variable): + value_type = float + entity = TaxUnit + label = "Louisiana income tax before credits" + unit = USD + definition_period = YEAR + reference = ( + "https://revenue.louisiana.gov/TaxForms/IT540WEB(2022)%20F%20D2.pdf", + "https://revenue.louisiana.gov/TaxForms/IT540iWEB(2022)D1.pdf", + ) + defined_for = StateCode.LA + + def formula(tax_unit, period, parameters): + filing_status = tax_unit("filing_status", period) + statuses = filing_status.possible_values + taxable_income = tax_unit("la_taxable_income", period) + p = parameters(period).gov.states.la.tax.income.rates + return select( + [ + filing_status == statuses.SINGLE, + filing_status == statuses.SEPARATE, + filing_status == statuses.JOINT, + filing_status == statuses.WIDOW, + filing_status == statuses.HEAD_OF_HOUSEHOLD, + ], + [ + p.single.calc(taxable_income), + p.separate.calc(taxable_income), + p.joint.calc(taxable_income), + p.widow.calc(taxable_income), + p.head_of_household.calc(taxable_income), + ], + ) diff --git a/fiscalsim_us/variables/gov/states/la/tax/income/la_income_tax_before_refundable_credits.py b/fiscalsim_us/variables/gov/states/la/tax/income/la_income_tax_before_refundable_credits.py new file mode 100644 index 000000000..13b94418c --- /dev/null +++ b/fiscalsim_us/variables/gov/states/la/tax/income/la_income_tax_before_refundable_credits.py @@ -0,0 +1,19 @@ +from fiscalsim_us.model_api import * + + +class la_income_tax_before_refundable_credits(Variable): + value_type = float + entity = TaxUnit + label = "Louisiana income tax before refundable credits" + unit = USD + definition_period = YEAR + reference = ( + "https://revenue.louisiana.gov/TaxForms/IT540WEB(2022)%20F%20D2.pdf", + "https://revenue.louisiana.gov/TaxForms/IT540iWEB(2022)D1.pdf", + ) + defined_for = StateCode.LA + + def formula(tax_unit, period, parameters): + itax_before_credits = tax_unit("la_income_tax_before_credits", period) + nonrefundable_credits = tax_unit("la_nonrefundable_credits", period) + return max_(0, itax_before_credits - nonrefundable_credits) diff --git a/fiscalsim_us/variables/gov/states/la/tax/income/la_taxable_income.py b/fiscalsim_us/variables/gov/states/la/tax/income/la_taxable_income.py new file mode 100644 index 000000000..c424bd97f --- /dev/null +++ b/fiscalsim_us/variables/gov/states/la/tax/income/la_taxable_income.py @@ -0,0 +1,28 @@ +from fiscalsim_us.model_api import * + + +class la_taxable_income(Variable): + value_type = float + entity = TaxUnit + label = "Louisiana taxable income" + unit = USD + definition_period = YEAR + reference = ( + "https://revenue.louisiana.gov/TaxForms/IT540WEB(2022)%20F%20D2.pdf", + "https://revenue.louisiana.gov/TaxForms/IT540iWEB(2022)D1.pdf", + ) + defined_for = StateCode.LA + + def formula(tax_unit, period, parameters): + ADDS = ["adjusted_gross_income", "la_total_additions"] + SUBTRACTS = ["la_total_subtractions", "la_exemptions"] + + la_agi = add(tax_unit, period, ADDS) - add(tax_unit, period, SUBTRACTS) + + filing_status = tax_unit("fiscalsim_us", period) + std_deduct = parameters.gov.ird.deductions.standard.amount[filing_status] + medical_deduct = tax_unit("medical_expense_deduction", period) + + excess_fed_deduct = max_(0, medical_deduct - std_deduct) + + return max_(0, la_agi - excess_fed_deduct) From 79be82c613e9463c228b3f672e5f7e3b08203e53 Mon Sep 17 00:00:00 2001 From: mitchellpound Date: Thu, 8 Jun 2023 10:40:09 -0600 Subject: [PATCH 02/19] Added LA exemption logic --- .../income/exemptions/additional_amount.yaml | 13 ++++++++ .../income/exemptions/personal_amount.yaml | 13 ++++++++ .../gov/states/la/tax/income/la_exemptions.py | 30 +++++++++++++++++++ 3 files changed, 56 insertions(+) create mode 100644 fiscalsim_us/parameters/gov/states/la/tax/income/exemptions/additional_amount.yaml create mode 100644 fiscalsim_us/parameters/gov/states/la/tax/income/exemptions/personal_amount.yaml create mode 100644 fiscalsim_us/variables/gov/states/la/tax/income/la_exemptions.py diff --git a/fiscalsim_us/parameters/gov/states/la/tax/income/exemptions/additional_amount.yaml b/fiscalsim_us/parameters/gov/states/la/tax/income/exemptions/additional_amount.yaml new file mode 100644 index 000000000..10f7968f9 --- /dev/null +++ b/fiscalsim_us/parameters/gov/states/la/tax/income/exemptions/additional_amount.yaml @@ -0,0 +1,13 @@ +description: Louisiana allows this exemption from income for each additional exemption past the personal +values: + 2021-01-01: 1000 + +metadata: + period: year + unit: currency-USD + label: Louisiana additional exemption amount + reference: + - title: Louisiana Resident Income Tax Return Tax Table 2021 + href: "https://revenue.louisiana.gov/TaxForms/IT540TT%20(2021).pdf" + - title: Louisiana Resident Income Tax Return Tax Table 2022 + href: "https://revenue.louisiana.gov/TaxForms/IT540(2022)%20Tax%20Table.pdf" diff --git a/fiscalsim_us/parameters/gov/states/la/tax/income/exemptions/personal_amount.yaml b/fiscalsim_us/parameters/gov/states/la/tax/income/exemptions/personal_amount.yaml new file mode 100644 index 000000000..dec41e570 --- /dev/null +++ b/fiscalsim_us/parameters/gov/states/la/tax/income/exemptions/personal_amount.yaml @@ -0,0 +1,13 @@ +description: Louisiana allows this personal exemption from income +values: + 2021-01-01: 4_500 + +metadata: + period: year + unit: currency-USD + label: Louisiana personal exemption amount + reference: + - title: Louisiana Resident Income Tax Return Tax Table 2021 + href: "https://revenue.louisiana.gov/TaxForms/IT540TT%20(2021).pdf" + - title: Louisiana Resident Income Tax Return Tax Table 2022 + href: "https://revenue.louisiana.gov/TaxForms/IT540(2022)%20Tax%20Table.pdf" diff --git a/fiscalsim_us/variables/gov/states/la/tax/income/la_exemptions.py b/fiscalsim_us/variables/gov/states/la/tax/income/la_exemptions.py new file mode 100644 index 000000000..8ce240ebe --- /dev/null +++ b/fiscalsim_us/variables/gov/states/la/tax/income/la_exemptions.py @@ -0,0 +1,30 @@ +from fiscalsim_us.model_api import * + + +class la_exemptions(Variable): + value_type = float + entity = TaxUnit + label = "Louisiana exemptions amount" + unit = USD + definition_period = YEAR + reference = ( + ) + defined_for = StateCode.LA + + def formula(tax_unit, period, parameters): + + p = parameters(period).gov.states.la.tax.income.exemptions + filing_status = tax_unit("filing_status", period) + statuses = filing_status.possible_values + joint_separate = (filing_status == statuses.JOINT) | ( + filing_status == statuses.SEPARATE + ) + + dependents = tax_unit("tax_unit_dependents", period) - + where(joint_separate, 1, 0) + aged_blind = tax_unit("aged_blind_count", period) + + personal_multiplier = where(joint_separate, 2, 1) + n_extra = dependents + aged_blind + + return p.personal_amount * personal_multiplier + p.additional_amount * n_extra From acb8ad2701cfd29f32838ae70d4e3e8077d94b0e Mon Sep 17 00:00:00 2001 From: mitchellpound Date: Fri, 9 Jun 2023 15:10:39 -0600 Subject: [PATCH 03/19] Added non-refundable credits and tax rates --- .../tax/income/rates/head_of_household.yaml | 33 +++++++++++++++++++ .../gov/states/la/tax/income/rates/joint.yaml | 27 +++++++++++++++ .../states/la/tax/income/rates/separate.yaml | 27 +++++++++++++++ .../states/la/tax/income/rates/single.yaml | 27 +++++++++++++++ .../gov/states/la/tax/income/rates/widow.yaml | 27 +++++++++++++++ .../credits/la_nonrefundable_credits.py | 25 ++++++++++++++ 6 files changed, 166 insertions(+) create mode 100644 fiscalsim_us/parameters/gov/states/la/tax/income/rates/head_of_household.yaml create mode 100644 fiscalsim_us/parameters/gov/states/la/tax/income/rates/joint.yaml create mode 100644 fiscalsim_us/parameters/gov/states/la/tax/income/rates/separate.yaml create mode 100644 fiscalsim_us/parameters/gov/states/la/tax/income/rates/single.yaml create mode 100644 fiscalsim_us/parameters/gov/states/la/tax/income/rates/widow.yaml create mode 100644 fiscalsim_us/variables/gov/states/la/tax/income/credits/la_nonrefundable_credits.py diff --git a/fiscalsim_us/parameters/gov/states/la/tax/income/rates/head_of_household.yaml b/fiscalsim_us/parameters/gov/states/la/tax/income/rates/head_of_household.yaml new file mode 100644 index 000000000..6e3dc7aed --- /dev/null +++ b/fiscalsim_us/parameters/gov/states/la/tax/income/rates/head_of_household.yaml @@ -0,0 +1,33 @@ +description: Minnesota levies income taxes at these rates for filers who file as head of household. +brackets: + - threshold: + 2021-01-01: 0 + rate: + 2021-01-01: 0.0535 + - threshold: + 2021-01-01: 33_520 + 2022-01-01: 34_570 + rate: + 2021-01-01: 0.068 + - threshold: + 2021-01-01: 134_700 + 2022-01-01: 138_890 + rate: + 2021-01-01: 0.0785 + - threshold: + 2021-01-01: 220_730 + 2022-01-01: 227_600 + rate: + 2021-01-01: 0.0985 + +metadata: + type: marginal_rate + threshold_unit: currency-USD + rate_unit: /1 + threshold_period: year + label: Minnesota head of household income tax rates + reference: + - title: 2021 Minnesota M1 form instructions, Tax Rate Schedules + href: https://www.revenue.state.mn.us/sites/default/files/2023-01/m1_inst_21.pdf#page=35 + - title: 2022 Minnesota M1 form instructions, Tax Rate Schedules + href: https://www.revenue.state.mn.us/sites/default/files/2023-03/m1_inst_22.pdf#page=35 diff --git a/fiscalsim_us/parameters/gov/states/la/tax/income/rates/joint.yaml b/fiscalsim_us/parameters/gov/states/la/tax/income/rates/joint.yaml new file mode 100644 index 000000000..ae41cab65 --- /dev/null +++ b/fiscalsim_us/parameters/gov/states/la/tax/income/rates/joint.yaml @@ -0,0 +1,27 @@ +description: Louisiana levies income taxes at these rates for filers who are married filing jointly +brackets: + - threshold: + 2009-01-01: 0 + rate: + 2009-01-01: 0.02 + 2021-01-01: 0.0185 + - threshold: + 2009-01-01: 25_000 + rate: + 2009-01-01: 0.04 + 2021-01-01: 0.035 + - threshold: + 2009-01-01: 100_000 + rate: + 2009-01-01: 0.06 + 2021-01-01: 0.0425 + +metadata: + type: marginal_rate + threshold_unit: currency-USD + rate_unit: /1 + threshold_period: year + label: Louisiana married filing joint income tax rates + reference: + - title: Louisiana Department of Revenue Individual Income Tax + href: "https://revenue.louisiana.gov/individualincometax" diff --git a/fiscalsim_us/parameters/gov/states/la/tax/income/rates/separate.yaml b/fiscalsim_us/parameters/gov/states/la/tax/income/rates/separate.yaml new file mode 100644 index 000000000..9f71c5a44 --- /dev/null +++ b/fiscalsim_us/parameters/gov/states/la/tax/income/rates/separate.yaml @@ -0,0 +1,27 @@ +description: Louisiana levies income taxes at these rates for filers who file as single +brackets: + - threshold: + 2009-01-01: 0 + rate: + 2009-01-01: 0.02 + 2021-01-01: 0.0185 + - threshold: + 2009-01-01: 12_500 + rate: + 2009-01-01: 0.04 + 2021-01-01: 0.035 + - threshold: + 2009-01-01: 50_000 + rate: + 2009-01-01: 0.06 + 2021-01-01: 0.0425 + +metadata: + type: marginal_rate + threshold_unit: currency-USD + rate_unit: /1 + threshold_period: year + label: Louisiana single filer income tax rates + reference: + - title: Louisiana Department of Revenue Individual Income Tax + href: "https://revenue.louisiana.gov/individualincometax" diff --git a/fiscalsim_us/parameters/gov/states/la/tax/income/rates/single.yaml b/fiscalsim_us/parameters/gov/states/la/tax/income/rates/single.yaml new file mode 100644 index 000000000..9f71c5a44 --- /dev/null +++ b/fiscalsim_us/parameters/gov/states/la/tax/income/rates/single.yaml @@ -0,0 +1,27 @@ +description: Louisiana levies income taxes at these rates for filers who file as single +brackets: + - threshold: + 2009-01-01: 0 + rate: + 2009-01-01: 0.02 + 2021-01-01: 0.0185 + - threshold: + 2009-01-01: 12_500 + rate: + 2009-01-01: 0.04 + 2021-01-01: 0.035 + - threshold: + 2009-01-01: 50_000 + rate: + 2009-01-01: 0.06 + 2021-01-01: 0.0425 + +metadata: + type: marginal_rate + threshold_unit: currency-USD + rate_unit: /1 + threshold_period: year + label: Louisiana single filer income tax rates + reference: + - title: Louisiana Department of Revenue Individual Income Tax + href: "https://revenue.louisiana.gov/individualincometax" diff --git a/fiscalsim_us/parameters/gov/states/la/tax/income/rates/widow.yaml b/fiscalsim_us/parameters/gov/states/la/tax/income/rates/widow.yaml new file mode 100644 index 000000000..774c990a3 --- /dev/null +++ b/fiscalsim_us/parameters/gov/states/la/tax/income/rates/widow.yaml @@ -0,0 +1,27 @@ +description: Louisiana levies income taxes at these rates for filers who are a qualified suriving spouse (widow) +brackets: + - threshold: + 2009-01-01: 0 + rate: + 2009-01-01: 0.02 + 2021-01-01: 0.0185 + - threshold: + 2009-01-01: 25_000 + rate: + 2009-01-01: 0.04 + 2021-01-01: 0.035 + - threshold: + 2009-01-01: 100_000 + rate: + 2009-01-01: 0.06 + 2021-01-01: 0.0425 + +metadata: + type: marginal_rate + threshold_unit: currency-USD + rate_unit: /1 + threshold_period: year + label: Louisiana widow income tax rates + reference: + - title: Louisiana Department of Revenue Individual Income Tax + href: "https://revenue.louisiana.gov/individualincometax" diff --git a/fiscalsim_us/variables/gov/states/la/tax/income/credits/la_nonrefundable_credits.py b/fiscalsim_us/variables/gov/states/la/tax/income/credits/la_nonrefundable_credits.py new file mode 100644 index 000000000..d50562bcc --- /dev/null +++ b/fiscalsim_us/variables/gov/states/la/tax/income/credits/la_nonrefundable_credits.py @@ -0,0 +1,25 @@ +from fiscalsim_us.model_api import * + + +class la_nonrefundable_credits(Variable): + """ + Louisiana nonrefundable credits + Line 11 on Form IT-540. These credits include + the following with codes: + * 100 - Premium tax credit + * 120 - Bone Marrow credit + * 150 - Qualified Playgrounds + * 155 - Debt Issuance + * 199 - Other + """ + + value_type = float + entity = TaxUnit + label = "Louisiana nonrefundable credits" + unit = USD + definition_period = YEAR + reference = ( + "https://revenue.louisiana.gov/TaxForms/IT540WEB(2022)%20F%20D2.pdf", + "https://revenue.louisiana.gov/TaxForms/IT540iWEB(2022)D1.pdf" + ) + defined_for = StateCode.LA From 3bf3e830e032b4be1b429cb7e345d6afa8416524 Mon Sep 17 00:00:00 2001 From: mitchellpound Date: Fri, 23 Jun 2023 11:09:44 -0600 Subject: [PATCH 04/19] Added refundable and nonrefundable framework --- .../la/tax/income/credits/refundable.yaml | 11 +++++++ .../tax/income/rates/head_of_household.yaml | 32 ++++++++----------- .../states/la/tax/income/rates/separate.yaml | 4 +-- .../credits/la_nonrefundable_credits.py | 2 +- .../la_nonrefundable_priority_3_credits.py | 15 +++++++++ .../income/credits/la_refundable_credits.py | 32 +++++++++++++++++++ .../la_refundable_priority_2_credit.py | 15 +++++++++ .../la_refundable_priority_4_credits.py | 14 ++++++++ 8 files changed, 103 insertions(+), 22 deletions(-) create mode 100644 fiscalsim_us/parameters/gov/states/la/tax/income/credits/refundable.yaml create mode 100644 fiscalsim_us/variables/gov/states/la/tax/income/credits/la_nonrefundable_priority_3_credits.py create mode 100644 fiscalsim_us/variables/gov/states/la/tax/income/credits/la_refundable_credits.py create mode 100644 fiscalsim_us/variables/gov/states/la/tax/income/credits/la_refundable_priority_2_credit.py create mode 100644 fiscalsim_us/variables/gov/states/la/tax/income/credits/la_refundable_priority_4_credits.py diff --git a/fiscalsim_us/parameters/gov/states/la/tax/income/credits/refundable.yaml b/fiscalsim_us/parameters/gov/states/la/tax/income/credits/refundable.yaml new file mode 100644 index 000000000..e7bb29c70 --- /dev/null +++ b/fiscalsim_us/parameters/gov/states/la/tax/income/credits/refundable.yaml @@ -0,0 +1,11 @@ +description: Louisiana provides these refundable tax credits. +values: + 2021-01-01: + - TODO: Some credits here... + +metadata: + unit: variable + label: Louisiana other refundable tax credits + reference: + - title: Louisiana Form IT-540 Schedule F - Refundable credits + href: https://revenue.louisiana.gov/TaxForms/IT540iWEB(2022)D1.pdf diff --git a/fiscalsim_us/parameters/gov/states/la/tax/income/rates/head_of_household.yaml b/fiscalsim_us/parameters/gov/states/la/tax/income/rates/head_of_household.yaml index 6e3dc7aed..32d05f48b 100644 --- a/fiscalsim_us/parameters/gov/states/la/tax/income/rates/head_of_household.yaml +++ b/fiscalsim_us/parameters/gov/states/la/tax/income/rates/head_of_household.yaml @@ -1,33 +1,27 @@ -description: Minnesota levies income taxes at these rates for filers who file as head of household. +description: Louisiana levies income taxes at these rates for filers who file as head of household. brackets: - threshold: - 2021-01-01: 0 + 2009-01-01: 0 rate: - 2021-01-01: 0.0535 + 2009-01-01: 0.02 + 2021-01-01: 0.0185 - threshold: - 2021-01-01: 33_520 - 2022-01-01: 34_570 + 2009-01-01: 12_500 rate: - 2021-01-01: 0.068 + 2009-01-01: 0.04 + 2021-01-01: 0.035 - threshold: - 2021-01-01: 134_700 - 2022-01-01: 138_890 + 2009-01-01: 50_000 rate: - 2021-01-01: 0.0785 - - threshold: - 2021-01-01: 220_730 - 2022-01-01: 227_600 - rate: - 2021-01-01: 0.0985 + 2009-01-01: 0.06 + 2021-01-01: 0.0425 metadata: type: marginal_rate threshold_unit: currency-USD rate_unit: /1 threshold_period: year - label: Minnesota head of household income tax rates + label: Louisiana head of household income tax rates reference: - - title: 2021 Minnesota M1 form instructions, Tax Rate Schedules - href: https://www.revenue.state.mn.us/sites/default/files/2023-01/m1_inst_21.pdf#page=35 - - title: 2022 Minnesota M1 form instructions, Tax Rate Schedules - href: https://www.revenue.state.mn.us/sites/default/files/2023-03/m1_inst_22.pdf#page=35 + - title: Louisiana Department of Revenue Individual Income Tax + href: "https://revenue.louisiana.gov/individualincometax" diff --git a/fiscalsim_us/parameters/gov/states/la/tax/income/rates/separate.yaml b/fiscalsim_us/parameters/gov/states/la/tax/income/rates/separate.yaml index 9f71c5a44..86d5757f8 100644 --- a/fiscalsim_us/parameters/gov/states/la/tax/income/rates/separate.yaml +++ b/fiscalsim_us/parameters/gov/states/la/tax/income/rates/separate.yaml @@ -1,4 +1,4 @@ -description: Louisiana levies income taxes at these rates for filers who file as single +description: Louisiana levies income taxes at these rates for filers who are married filing separately brackets: - threshold: 2009-01-01: 0 @@ -21,7 +21,7 @@ metadata: threshold_unit: currency-USD rate_unit: /1 threshold_period: year - label: Louisiana single filer income tax rates + label: Louisiana married filing separately income tax rates reference: - title: Louisiana Department of Revenue Individual Income Tax href: "https://revenue.louisiana.gov/individualincometax" diff --git a/fiscalsim_us/variables/gov/states/la/tax/income/credits/la_nonrefundable_credits.py b/fiscalsim_us/variables/gov/states/la/tax/income/credits/la_nonrefundable_credits.py index d50562bcc..b219c7847 100644 --- a/fiscalsim_us/variables/gov/states/la/tax/income/credits/la_nonrefundable_credits.py +++ b/fiscalsim_us/variables/gov/states/la/tax/income/credits/la_nonrefundable_credits.py @@ -3,7 +3,7 @@ class la_nonrefundable_credits(Variable): """ - Louisiana nonrefundable credits + Louisiana nonrefundable priority 1 credits Line 11 on Form IT-540. These credits include the following with codes: * 100 - Premium tax credit diff --git a/fiscalsim_us/variables/gov/states/la/tax/income/credits/la_nonrefundable_priority_3_credits.py b/fiscalsim_us/variables/gov/states/la/tax/income/credits/la_nonrefundable_priority_3_credits.py new file mode 100644 index 000000000..e63142ef0 --- /dev/null +++ b/fiscalsim_us/variables/gov/states/la/tax/income/credits/la_nonrefundable_priority_3_credits.py @@ -0,0 +1,15 @@ +from fiscalsim_us.model_api import * + + +class la_nonrefundable_priority_3_credits(Variable): + value_type = float + entity = TaxUnit + label = "Louisiana nonrefundable priority 3 income tax credits" + unit = USD + definition_period = YEAR + defined_for = StateCode.LA + reference = ( + "https://revenue.louisiana.gov/TaxForms/IT540WEB(2022)%20F%20D2.pdf", + "https://revenue.louisiana.gov/TaxForms/IT540iWEB(2022)D1.pdf" + ) + diff --git a/fiscalsim_us/variables/gov/states/la/tax/income/credits/la_refundable_credits.py b/fiscalsim_us/variables/gov/states/la/tax/income/credits/la_refundable_credits.py new file mode 100644 index 000000000..9192e0316 --- /dev/null +++ b/fiscalsim_us/variables/gov/states/la/tax/income/credits/la_refundable_credits.py @@ -0,0 +1,32 @@ +from fiscalsim_us.model_api import * + + +class la_refundable_credits(Variable): + value_type = float + entity = TaxUnit + label = "Louisiana refundable income tax credits" + unit = USD + definition_period = YEAR + defined_for = StateCode.LA + reference = ( + "https://revenue.louisiana.gov/TaxForms/IT540WEB(2022)%20F%20D2.pdf", + "https://revenue.louisiana.gov/TaxForms/IT540iWEB(2022)D1.pdf" + ) + + def formula(tax_unit, period, parameters): + + priority_2_refund = tax_unit("la_refundable_priority_2_credits", period) + + # line 18 - floor at 0 since the priority 3 credits are nonrefundable + tax_afer_p_2_credits = max_( + 0, + tax_unit("la_income_tax_before_refundable_credits", period) - priority_2_refund + ) + + priority_3_nonrefund_amount = tax_unit("la_nonrefundable_priority_3_credits", period) + + priority_3_nonrefund_add = max_(tax_afer_p_2_credits, priority_3_nonrefund_amount) + + priority_4_refund = tax_unit("la_refundable_priority_4_credits", tax_unit) + + return priority_3_eligible + priority_3_nonrefund_add + priority_4_refund diff --git a/fiscalsim_us/variables/gov/states/la/tax/income/credits/la_refundable_priority_2_credit.py b/fiscalsim_us/variables/gov/states/la/tax/income/credits/la_refundable_priority_2_credit.py new file mode 100644 index 000000000..c8bcb0899 --- /dev/null +++ b/fiscalsim_us/variables/gov/states/la/tax/income/credits/la_refundable_priority_2_credit.py @@ -0,0 +1,15 @@ +from fiscalsim_us.model_api import * + + +class la_refundable_priority_2_credits(Variable): + value_type = float + entity = TaxUnit + label = "Louisiana refundable priority 2 income tax credits" + unit = USD + definition_period = YEAR + defined_for = StateCode.LA + reference = ( + "https://revenue.louisiana.gov/TaxForms/IT540WEB(2022)%20F%20D2.pdf", + "https://revenue.louisiana.gov/TaxForms/IT540iWEB(2022)D1.pdf" + ) + diff --git a/fiscalsim_us/variables/gov/states/la/tax/income/credits/la_refundable_priority_4_credits.py b/fiscalsim_us/variables/gov/states/la/tax/income/credits/la_refundable_priority_4_credits.py new file mode 100644 index 000000000..ccd475a08 --- /dev/null +++ b/fiscalsim_us/variables/gov/states/la/tax/income/credits/la_refundable_priority_4_credits.py @@ -0,0 +1,14 @@ +from fiscalsim_us.model_api import * + + +class la_refundable_priority_4_credits(Variable): + value_type = float + entity = TaxUnit + label = "Louisiana refundable priority 4 income tax credits" + unit = USD + definition_period = YEAR + defined_for = StateCode.LA + reference = ( + "https://revenue.louisiana.gov/TaxForms/IT540WEB(2022)%20F%20D2.pdf", + "https://revenue.louisiana.gov/TaxForms/IT540iWEB(2022)D1.pdf" + ) From 8292daeba2bf335cf6476379d2d73c453771ede2 Mon Sep 17 00:00:00 2001 From: mitchellpound Date: Mon, 3 Jul 2023 11:50:59 -0600 Subject: [PATCH 05/19] Added refundable childcare credit logic --- .../childcare_child_age_limit.yaml | 13 ++++++ .../childcare_expense_limit.yaml | 26 ++++++++++++ .../refundable_p2/childcare_income_mult.yaml | 41 +++++++++++++++++++ .../refundable_childcare_mult.yaml | 13 ++++++ .../income/credits/refundable_p2/sources.yaml | 11 +++++ .../income/credits/la_refundable_childcare.py | 40 ++++++++++++++++++ .../la_refundable_priority_2_credit.py | 1 + 7 files changed, 145 insertions(+) create mode 100644 fiscalsim_us/parameters/gov/states/la/tax/income/credits/refundable_p2/childcare_child_age_limit.yaml create mode 100644 fiscalsim_us/parameters/gov/states/la/tax/income/credits/refundable_p2/childcare_expense_limit.yaml create mode 100644 fiscalsim_us/parameters/gov/states/la/tax/income/credits/refundable_p2/childcare_income_mult.yaml create mode 100644 fiscalsim_us/parameters/gov/states/la/tax/income/credits/refundable_p2/refundable_childcare_mult.yaml create mode 100644 fiscalsim_us/parameters/gov/states/la/tax/income/credits/refundable_p2/sources.yaml create mode 100644 fiscalsim_us/variables/gov/states/la/tax/income/credits/la_refundable_childcare.py diff --git a/fiscalsim_us/parameters/gov/states/la/tax/income/credits/refundable_p2/childcare_child_age_limit.yaml b/fiscalsim_us/parameters/gov/states/la/tax/income/credits/refundable_p2/childcare_child_age_limit.yaml new file mode 100644 index 000000000..38153753a --- /dev/null +++ b/fiscalsim_us/parameters/gov/states/la/tax/income/credits/refundable_p2/childcare_child_age_limit.yaml @@ -0,0 +1,13 @@ +description: Louisiana allows refundbale childcare credit for childcare expenses for children under this age limit +values: + 2021-01-01: 13 + +metadata: + period: year + unit: year + label: Louisiana refundbale childcare age limit + reference: + - title: Louisiana Resident Income Tax Return Tax Table 2021 + href: "https://revenue.louisiana.gov/TaxForms/IT540TT%20(2021).pdf" + - title: Louisiana Resident Income Tax Return Tax Table 2022 + href: "https://revenue.louisiana.gov/TaxForms/IT540(2022)%20Tax%20Table.pdf" diff --git a/fiscalsim_us/parameters/gov/states/la/tax/income/credits/refundable_p2/childcare_expense_limit.yaml b/fiscalsim_us/parameters/gov/states/la/tax/income/credits/refundable_p2/childcare_expense_limit.yaml new file mode 100644 index 000000000..3bced9ae1 --- /dev/null +++ b/fiscalsim_us/parameters/gov/states/la/tax/income/credits/refundable_p2/childcare_expense_limit.yaml @@ -0,0 +1,26 @@ +description: Childcare expense limit for Louisiana refundable childcare credit +brackets: + - threshold: + 2021-01-01: 0 + amount: + 2021-01-01: 0 + - threshold: + 2021-01-01: 1 + amount: + 2021-01-01: 8_000 + 2022-01-01: 3_000 + - threshold: + 2021-01-01: 2 + amount: + 2021-01-01: 16_000 + 2021-01-01: 6_000 + +metadata: + type: single_amount + threshold_unit: child-dependents + rate_unit: /1 + threshold_period: year + label: Louisiana refundbale childcare credit income multiplier + reference: + - title: 2022 Louisiana Refundable Child Care Credit Worksheet + href: https://revenue.louisiana.gov/TaxForms/IT540WEB(2022)%20F%20D2.pdf diff --git a/fiscalsim_us/parameters/gov/states/la/tax/income/credits/refundable_p2/childcare_income_mult.yaml b/fiscalsim_us/parameters/gov/states/la/tax/income/credits/refundable_p2/childcare_income_mult.yaml new file mode 100644 index 000000000..f08ae8f8e --- /dev/null +++ b/fiscalsim_us/parameters/gov/states/la/tax/income/credits/refundable_p2/childcare_income_mult.yaml @@ -0,0 +1,41 @@ +description: Income multiplier for Louisiana refundable childcare credit +brackets: + - threshold: + 2021-01-01: 0 + amount: + 2021-01-01: 0.5 + 2022-01-01: 0.35 + - threshold: + 2022-01-01: 15_000 + amount: + 2022-01-01: 0.34 + - threshold: + 2022-01-01: 17_000 + amount: + 2022-01-01: 0.33 + - threshold: + 2022-01-01: 19_000 + amount: + 2022-01-01: 0.32 + - threshold: + 2022-01-01: 21_000 + amount: + 2022-01-01: 0.31 + - threshold: + 2022-01-01: 23_000 + amount: + 2022-01-01: 0.39 + - threshold: + 2021-01-01: 25_000 + amount: + 2021-01-01: 0.0 + +metadata: + type: single_amount + threshold_unit: currency-USD + rate_unit: /1 + threshold_period: year + label: Louisiana refundbale childcare credit income multiplier + reference: + - title: 2022 Louisiana Refundable Child Care Credit Worksheet + href: https://revenue.louisiana.gov/TaxForms/IT540WEB(2022)%20F%20D2.pdf diff --git a/fiscalsim_us/parameters/gov/states/la/tax/income/credits/refundable_p2/refundable_childcare_mult.yaml b/fiscalsim_us/parameters/gov/states/la/tax/income/credits/refundable_p2/refundable_childcare_mult.yaml new file mode 100644 index 000000000..75e5a19b3 --- /dev/null +++ b/fiscalsim_us/parameters/gov/states/la/tax/income/credits/refundable_p2/refundable_childcare_mult.yaml @@ -0,0 +1,13 @@ +description: multiplier for Louisiana childcare credit (applied to everyone) +values: + 2021-01-01: .5 + +metadata: + period: year + unit: /1 + label: Louisiana refundbale childcare multiplier + reference: + - title: Louisiana Resident Income Tax Return Tax Table 2021 + href: "https://revenue.louisiana.gov/TaxForms/IT540TT%20(2021).pdf" + - title: Louisiana Resident Income Tax Return Tax Table 2022 + href: "https://revenue.louisiana.gov/TaxForms/IT540(2022)%20Tax%20Table.pdf" diff --git a/fiscalsim_us/parameters/gov/states/la/tax/income/credits/refundable_p2/sources.yaml b/fiscalsim_us/parameters/gov/states/la/tax/income/credits/refundable_p2/sources.yaml new file mode 100644 index 000000000..08d91d5d2 --- /dev/null +++ b/fiscalsim_us/parameters/gov/states/la/tax/income/credits/refundable_p2/sources.yaml @@ -0,0 +1,11 @@ +description: Louisiana provides these refundable priority 2 tax credits. +values: + 2021-01-01: + - la_refundable_childcare + +metadata: + unit: variable + label: Louisiana refundable priorty 2 tax credits + reference: + - title: Louisiana Form IT-540 Schedule F - Refundable credits + href: https://revenue.louisiana.gov/TaxForms/IT540iWEB(2022)D1.pdf diff --git a/fiscalsim_us/variables/gov/states/la/tax/income/credits/la_refundable_childcare.py b/fiscalsim_us/variables/gov/states/la/tax/income/credits/la_refundable_childcare.py new file mode 100644 index 000000000..160f03d40 --- /dev/null +++ b/fiscalsim_us/variables/gov/states/la/tax/income/credits/la_refundable_childcare.py @@ -0,0 +1,40 @@ +from fiscalsim_us.model_api import * + + +class la_refundable_childcare(Variable): + value_type = float + entity = TaxUnit + label = "Louisiana refundable childcare credits" + unit = USD + definition_period = YEAR + defined_for = StateCode.LA + reference = ( + "https://revenue.louisiana.gov/TaxForms/IT540WEB(2022)%20F%20D2.pdf", + "https://revenue.louisiana.gov/TaxForms/IT540iWEB(2022)D1.pdf" + ) + + def formula(tax_unit, period, parameters): + + p = parameters(period).gov.states.la.tax.income.credits.refundable_p2 + agi = tax_unit("adjusted_gross_income", period) + earned_income = tax_unit("tax_unit_earned_income", period) + childcare_expenses = tax_unit("tax_unit_childcare_expenses", period) + + # check for eligible children + person = tax_unit.members + dependent = person("is_tax_unit_dependent", period) + age = person("age", period) + child = age < p.childcare_child_age_limit + eligible = dependent & child + eligible_children = tax_unit.sum(eligible_child) + + max_expense = p.childcare_expense_limit.calc(eligible_children) + expense = min_(childcare_expenses, max_expense) + + # line 6 of worksheet + credit = min_(expense, earned_income) + + income_mult = p.childcare_income_mult.calc(agi) + mult = p.refundable_childcare_mult + + return credit * income_mult * mult diff --git a/fiscalsim_us/variables/gov/states/la/tax/income/credits/la_refundable_priority_2_credit.py b/fiscalsim_us/variables/gov/states/la/tax/income/credits/la_refundable_priority_2_credit.py index c8bcb0899..72be88197 100644 --- a/fiscalsim_us/variables/gov/states/la/tax/income/credits/la_refundable_priority_2_credit.py +++ b/fiscalsim_us/variables/gov/states/la/tax/income/credits/la_refundable_priority_2_credit.py @@ -12,4 +12,5 @@ class la_refundable_priority_2_credits(Variable): "https://revenue.louisiana.gov/TaxForms/IT540WEB(2022)%20F%20D2.pdf", "https://revenue.louisiana.gov/TaxForms/IT540iWEB(2022)D1.pdf" ) + adds = gov.states.la.tax.income.credits.nonrefundable_p2 From 183c61263968de5640caf3d4a4c508018be9d083 Mon Sep 17 00:00:00 2001 From: mitchellpound Date: Mon, 3 Jul 2023 12:01:53 -0600 Subject: [PATCH 06/19] Added LA refundable priority 4 doc string --- .../tax/income/credits/la_refundable_priority_4_credits.py | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/fiscalsim_us/variables/gov/states/la/tax/income/credits/la_refundable_priority_4_credits.py b/fiscalsim_us/variables/gov/states/la/tax/income/credits/la_refundable_priority_4_credits.py index ccd475a08..3ef88b605 100644 --- a/fiscalsim_us/variables/gov/states/la/tax/income/credits/la_refundable_priority_4_credits.py +++ b/fiscalsim_us/variables/gov/states/la/tax/income/credits/la_refundable_priority_4_credits.py @@ -2,6 +2,13 @@ class la_refundable_priority_4_credits(Variable): + """ + louisiana refundable priority 4 credits + Line 25 on Form IT-540. These credits include the + following with codes: + * 50F - Inventory Tax + * 51F - Ad Valorem Natural Gas + """ value_type = float entity = TaxUnit label = "Louisiana refundable priority 4 income tax credits" From bccbe9406f80708a6b7b0f4febe953a66d48ef14 Mon Sep 17 00:00:00 2001 From: mitchellpound Date: Fri, 7 Jul 2023 16:22:24 -0600 Subject: [PATCH 07/19] Added subtractions from income logic --- .../tax/income/agi/subtractions/sources.yaml | 16 ++++++++ .../la/tax/income/credits/refundable.yaml | 11 ----- .../credits/refundable_p2/eitc_mult.yaml | 13 ++++++ .../income/credits/refundable_p2/sources.yaml | 3 ++ .../agi/la_federal_retirement_benefits.py | 15 +++++++ .../tax/income/agi/la_other_subtractions.py | 40 ++++++++++++++++++ .../la_state_employee_retirement_benefits.py | 10 +++++ .../la_state_teacher_retirement_benefits.py | 10 +++++ .../tax/income/agi/la_total_subtractions.py | 5 ++- .../states/la/tax/income/credits/la_eitc.py | 25 +++++++++++ .../la_nonrefundable_priority_3_credits.py | 41 +++++++++++++++++++ .../income/credits/la_other_refundable_p2.py | 38 +++++++++++++++++ .../la_refundable_priority_2_credit.py | 2 +- .../credits/la_refundable_school_ready.py | 18 ++++++++ 14 files changed, 233 insertions(+), 14 deletions(-) create mode 100644 fiscalsim_us/parameters/gov/states/la/tax/income/agi/subtractions/sources.yaml delete mode 100644 fiscalsim_us/parameters/gov/states/la/tax/income/credits/refundable.yaml create mode 100644 fiscalsim_us/parameters/gov/states/la/tax/income/credits/refundable_p2/eitc_mult.yaml create mode 100644 fiscalsim_us/variables/gov/states/la/tax/income/agi/la_federal_retirement_benefits.py create mode 100644 fiscalsim_us/variables/gov/states/la/tax/income/agi/la_other_subtractions.py create mode 100644 fiscalsim_us/variables/gov/states/la/tax/income/agi/la_state_employee_retirement_benefits.py create mode 100644 fiscalsim_us/variables/gov/states/la/tax/income/agi/la_state_teacher_retirement_benefits.py create mode 100644 fiscalsim_us/variables/gov/states/la/tax/income/credits/la_eitc.py create mode 100644 fiscalsim_us/variables/gov/states/la/tax/income/credits/la_other_refundable_p2.py create mode 100644 fiscalsim_us/variables/gov/states/la/tax/income/credits/la_refundable_school_ready.py diff --git a/fiscalsim_us/parameters/gov/states/la/tax/income/agi/subtractions/sources.yaml b/fiscalsim_us/parameters/gov/states/la/tax/income/agi/subtractions/sources.yaml new file mode 100644 index 000000000..c3671ce7a --- /dev/null +++ b/fiscalsim_us/parameters/gov/states/la/tax/income/agi/subtractions/sources.yaml @@ -0,0 +1,16 @@ +description: Louisiana allows these subtractions (exemptions) from taxable income +values: + 2021-01-01: + - us_govt_income + - tax_unit_taxable_social_security + - la_state_employee_retirement_benefits + - la_state_teacher_retirement_benefits + - la_federal_retirement_benefits + - la_other_subtractions + +metadata: + unit: variable + label: Louisiana subtractions from income + reference: + - title: Louisiana Form IT-540 Schedule F - Refundable credits + href: https://revenue.louisiana.gov/TaxForms/IT540iWEB(2022)D1.pdf diff --git a/fiscalsim_us/parameters/gov/states/la/tax/income/credits/refundable.yaml b/fiscalsim_us/parameters/gov/states/la/tax/income/credits/refundable.yaml deleted file mode 100644 index e7bb29c70..000000000 --- a/fiscalsim_us/parameters/gov/states/la/tax/income/credits/refundable.yaml +++ /dev/null @@ -1,11 +0,0 @@ -description: Louisiana provides these refundable tax credits. -values: - 2021-01-01: - - TODO: Some credits here... - -metadata: - unit: variable - label: Louisiana other refundable tax credits - reference: - - title: Louisiana Form IT-540 Schedule F - Refundable credits - href: https://revenue.louisiana.gov/TaxForms/IT540iWEB(2022)D1.pdf diff --git a/fiscalsim_us/parameters/gov/states/la/tax/income/credits/refundable_p2/eitc_mult.yaml b/fiscalsim_us/parameters/gov/states/la/tax/income/credits/refundable_p2/eitc_mult.yaml new file mode 100644 index 000000000..584469549 --- /dev/null +++ b/fiscalsim_us/parameters/gov/states/la/tax/income/credits/refundable_p2/eitc_mult.yaml @@ -0,0 +1,13 @@ +description: Multiplier for the amount of the federal EITC that Louisiana allows taxfiliers for a refundable credit +values: + 2021-01-01: .05 + +metadata: + period: year + unit: /1 + label: Louisiana EITC multiplier + reference: + - title: Louisiana State Inncome Tax Form IT-540 2021 + href: "https://revenue.louisiana.gov/TaxForms/IT540WEB(2021)%20F.pdf" + - title: Louisiana State Inncome Tax Form IT-540 2022 + href: "https://revenue.louisiana.gov/TaxForms/IT540WEB(2022)%20F%20D2.pdf" diff --git a/fiscalsim_us/parameters/gov/states/la/tax/income/credits/refundable_p2/sources.yaml b/fiscalsim_us/parameters/gov/states/la/tax/income/credits/refundable_p2/sources.yaml index 08d91d5d2..26bebdb84 100644 --- a/fiscalsim_us/parameters/gov/states/la/tax/income/credits/refundable_p2/sources.yaml +++ b/fiscalsim_us/parameters/gov/states/la/tax/income/credits/refundable_p2/sources.yaml @@ -2,6 +2,9 @@ description: Louisiana provides these refundable priority 2 tax credits. values: 2021-01-01: - la_refundable_childcare + - la_refundable_school_ready + - la_eitc + - la_other_refundable_p2 metadata: unit: variable diff --git a/fiscalsim_us/variables/gov/states/la/tax/income/agi/la_federal_retirement_benefits.py b/fiscalsim_us/variables/gov/states/la/tax/income/agi/la_federal_retirement_benefits.py new file mode 100644 index 000000000..afb05c049 --- /dev/null +++ b/fiscalsim_us/variables/gov/states/la/tax/income/agi/la_federal_retirement_benefits.py @@ -0,0 +1,15 @@ +from fiscalsim_us.model_api import * + + +class la_federal_retirement_benefits(Variable): + "Amount of retirement benefits recieved from a + Federal Retirement System + """ + value_type = float + entity = TaxUnit + label = "Louisiana state teacher retirement benefits" + unit = USD + definition_period = YEAR + defined_for = StateCode.LA + # If this gets implimented in a federal level variable + # delete this one and change in parameter subtractions.sources.yaml diff --git a/fiscalsim_us/variables/gov/states/la/tax/income/agi/la_other_subtractions.py b/fiscalsim_us/variables/gov/states/la/tax/income/agi/la_other_subtractions.py new file mode 100644 index 000000000..71d170650 --- /dev/null +++ b/fiscalsim_us/variables/gov/states/la/tax/income/agi/la_other_subtractions.py @@ -0,0 +1,40 @@ +from fiscalsim_us.model_api import * + + +class la_other_subtractions(Variable): + """ + Other subtractions from louisiana taxable income. + These include the following exemptions from income with + the associated codes: + 05E – Other Retirement Benefits + 06E – Annual Retirement Income Exemption for Taxpayers 65 + Years of Age or Older + 08E – Native American Income + 09E – START Savings Program Contribution + 10E – Military Pay Exclusion + 11E – Road Home + 13E – Recreation Volunteer + 14E – Volunteer Firefighter + 16E – Voluntary Retrofit Residential Structure + 17E – Elementary and Secondary School Tuition + 18E – Educational Expenses for Home-Schooled Children + 19E – Educational Expenses for a Quality Public Education + 20E – Capital Gain from Sale of Louisiana Business + 21E – Employment of Certain Qualified Disabled Individuals + 22E – S Bank Shareholder Income Exclusion + 23E – Entity Level Taxes Paid to Other States + 24E – Pass–Through Entity Exclusion + 25E – IRC 280C Expense + 27E – COVID-19 Relief Benefits + 28E – START K12 Savings Program Contributions + 29E – Digital Nomad + 30E – Certain Adoptions + """ + + value_type = float + entity = TaxUnit + label = "Louisiana other subtractions from AGI" + unit = USD + definition_period = YEAR + defined_for = StateCode.LA + adds = gov.states.la.tax.income.agi.subtractions.sources diff --git a/fiscalsim_us/variables/gov/states/la/tax/income/agi/la_state_employee_retirement_benefits.py b/fiscalsim_us/variables/gov/states/la/tax/income/agi/la_state_employee_retirement_benefits.py new file mode 100644 index 000000000..aa55e2c8b --- /dev/null +++ b/fiscalsim_us/variables/gov/states/la/tax/income/agi/la_state_employee_retirement_benefits.py @@ -0,0 +1,10 @@ +from fiscalsim_us.model_api import * + + +class la_state_employee_retirement_benefits(Variable): + value_type = float + entity = TaxUnit + label = "Louisiana state empoyees' retirement benefits" + unit = USD + definition_period = YEAR + defined_for = StateCode.LA diff --git a/fiscalsim_us/variables/gov/states/la/tax/income/agi/la_state_teacher_retirement_benefits.py b/fiscalsim_us/variables/gov/states/la/tax/income/agi/la_state_teacher_retirement_benefits.py new file mode 100644 index 000000000..18677ec5b --- /dev/null +++ b/fiscalsim_us/variables/gov/states/la/tax/income/agi/la_state_teacher_retirement_benefits.py @@ -0,0 +1,10 @@ +from fiscalsim_us.model_api import * + + +class la_state_teacher_retirement_benefits(Variable): + value_type = float + entity = TaxUnit + label = "Louisiana state teacher retirement benefits" + unit = USD + definition_period = YEAR + defined_for = StateCode.LA diff --git a/fiscalsim_us/variables/gov/states/la/tax/income/agi/la_total_subtractions.py b/fiscalsim_us/variables/gov/states/la/tax/income/agi/la_total_subtractions.py index aa8704620..2fb20bb78 100644 --- a/fiscalsim_us/variables/gov/states/la/tax/income/agi/la_total_subtractions.py +++ b/fiscalsim_us/variables/gov/states/la/tax/income/agi/la_total_subtractions.py @@ -1,9 +1,9 @@ from fiscalsim_us.model_api import * -class la_total_additions(Variable): +class la_total_subtractions(Variable): """ - subtractions from louisiana adjusted income + Subtractions from louisiana adjusted income """ value_type = float @@ -12,3 +12,4 @@ class la_total_additions(Variable): unit = USD definition_period = YEAR defined_for = StateCode.LA + adds = gov.states.la.tax.income.agi.subtractions.sources diff --git a/fiscalsim_us/variables/gov/states/la/tax/income/credits/la_eitc.py b/fiscalsim_us/variables/gov/states/la/tax/income/credits/la_eitc.py new file mode 100644 index 000000000..f472d8f12 --- /dev/null +++ b/fiscalsim_us/variables/gov/states/la/tax/income/credits/la_eitc.py @@ -0,0 +1,25 @@ +from fiscalsim_us.model_api import * + + +class la_eitc(Variable): + """ + Louisiana earned income tax credit + """ + + value_type = float + entity = TaxUnit + label = "Louisiana EITC" + unit = USD + definition_period = YEAR + reference = ( + "https://revenue.louisiana.gov/TaxForms/IT540WEB(2022)%20F%20D2.pdf", + "https://revenue.louisiana.gov/TaxForms/IT540iWEB(2022)D1.pdf" + ) + defined_for = StateCode.LA + + def formula(tax_unit, period, parameters): + + federal_eitc = tax_unit("earned_income_tax_credit", period) + p = parameters(period).gov.states.la.tax.income.credits.refundable_p2 + + return federal_eitc * p.eitc_mult diff --git a/fiscalsim_us/variables/gov/states/la/tax/income/credits/la_nonrefundable_priority_3_credits.py b/fiscalsim_us/variables/gov/states/la/tax/income/credits/la_nonrefundable_priority_3_credits.py index e63142ef0..6b8021682 100644 --- a/fiscalsim_us/variables/gov/states/la/tax/income/credits/la_nonrefundable_priority_3_credits.py +++ b/fiscalsim_us/variables/gov/states/la/tax/income/credits/la_nonrefundable_priority_3_credits.py @@ -2,6 +2,47 @@ class la_nonrefundable_priority_3_credits(Variable): + """ + Louisiana nonrefundable priority 3 credits + Form IT-540 line 20 + These include the following credits with codes: + 202 – Organ Donation + 208 – Previously Unemployed + 221 – Owner of Accessible and Barrier-free Home – + 224 – New Jobs Credit + 228 – Eligible Re-entrants – + 236 – Apprenticeship (2007) + 251 – Motion Picture Investment + 252 – Research and Development + 253 – Historic Structures + 254 – Digital Interactive Media + 257 – Capital Company + 258 – LA Community Development Financial Institution (LCDFI) + 259 – New Markets + 261 – Motion Picture Infrastructure + 262 – Angel Investor + 300 – Biomed/University Research + 305 – Tax Equalization + 310 – Manufacturing Establishment + 412 – Refund by Utilities + 424 – Donation to School Tuition Organization + 454 – QMC Music Job Creation Credit + 457 – Neighborhood Assistance + 458 – Research and Development + 459 – Ports of Louisiana Import Export Cargo + 460 – LA Import + 461 – LA Work Opportunity + 462 – Youth Jobs + 463 – Apprenticeship (2022) + 464 – Donation to Qualified Foster Care Charitable Organization + 500 – Inventory Tax Credit Carried Forward and ITEP + 502 – Ad Valorem Natural Gas Credit Carried Forward + 504 – Atchafalaya Trace + 506 – Cane River Heritage + 508 – Ports of Louisiana Investor + 510 – Enterprise Zone + 550 – Recycling Credit + """ value_type = float entity = TaxUnit label = "Louisiana nonrefundable priority 3 income tax credits" diff --git a/fiscalsim_us/variables/gov/states/la/tax/income/credits/la_other_refundable_p2.py b/fiscalsim_us/variables/gov/states/la/tax/income/credits/la_other_refundable_p2.py new file mode 100644 index 000000000..26b0919a2 --- /dev/null +++ b/fiscalsim_us/variables/gov/states/la/tax/income/credits/la_other_refundable_p2.py @@ -0,0 +1,38 @@ +from fiscalsim_us.model_api import * + + +class la_other_refundable_p2(Variable): + """ + Other Louisiana refundable priority 2 credits listed + on Schedule F for IT-540. These credits include the + following with codes: + * 52F - Ad Valorem Offshore Vessels + * 54F – Telephone Company Property + * 54F – Telephone Company Property + * 58F – Milk Producers + * 59F – Technology Commercialization + * 60F – Historic Residential + * 62F – Musical and Theatrical Production + * 65F – School Readiness Child Care Provider + * 66F – School Readiness Child Care Directors and Staff + * 67F – School Readiness Business-Supported Child Care + * 68F – School Readiness Fees and Grants to Resource and + Referral Agencies + * 70F – Retention and Modernization + * 73F – Digital Interactive Media & Software + * 76F – Stillborn Child + * 77F – Funeral and Burial Expense for a Pregnancy-related Death + * 80F – Other Refundable Credit + """ + unit = USD + value_type = float + entity = TaxUnit + label = "Louisiana other refundable priority 2 income tax credits" + unit = USD + definition_period = YEAR + defined_for = StateCode.LA + reference = ( + "https://revenue.louisiana.gov/TaxForms/IT540WEB(2022)%20F%20D2.pdf", + "https://revenue.louisiana.gov/TaxForms/IT540iWEB(2022)D1.pdf" + ) + diff --git a/fiscalsim_us/variables/gov/states/la/tax/income/credits/la_refundable_priority_2_credit.py b/fiscalsim_us/variables/gov/states/la/tax/income/credits/la_refundable_priority_2_credit.py index 72be88197..669ac4203 100644 --- a/fiscalsim_us/variables/gov/states/la/tax/income/credits/la_refundable_priority_2_credit.py +++ b/fiscalsim_us/variables/gov/states/la/tax/income/credits/la_refundable_priority_2_credit.py @@ -12,5 +12,5 @@ class la_refundable_priority_2_credits(Variable): "https://revenue.louisiana.gov/TaxForms/IT540WEB(2022)%20F%20D2.pdf", "https://revenue.louisiana.gov/TaxForms/IT540iWEB(2022)D1.pdf" ) - adds = gov.states.la.tax.income.credits.nonrefundable_p2 + adds = gov.states.la.tax.income.credits.nonrefundable_p2.sources diff --git a/fiscalsim_us/variables/gov/states/la/tax/income/credits/la_refundable_school_ready.py b/fiscalsim_us/variables/gov/states/la/tax/income/credits/la_refundable_school_ready.py new file mode 100644 index 000000000..431656acb --- /dev/null +++ b/fiscalsim_us/variables/gov/states/la/tax/income/credits/la_refundable_school_ready.py @@ -0,0 +1,18 @@ +from fiscalsim_us.model_api import * + + +class la_refundable_school_ready(Variable): + """ + louisiana refundable school readiness credit + Line 14 on Form IT-540. + """ + value_type = float + entity = TaxUnit + label = "Louisiana refundable priority 4 income tax credits" + unit = USD + definition_period = YEAR + defined_for = StateCode.LA + reference = ( + "https://revenue.louisiana.gov/TaxForms/IT540WEB(2022)%20F%20D2.pdf", + "https://revenue.louisiana.gov/TaxForms/IT540iWEB(2022)D1.pdf" + ) From f44326bb576974cac40b6e07bdfbaacaf9729622 Mon Sep 17 00:00:00 2001 From: mitchellpound Date: Mon, 31 Jul 2023 21:57:20 -0600 Subject: [PATCH 08/19] Minor bug fixes --- .../income/credits/refundable_p2/childcare_expense_limit.yaml | 2 +- .../states/la/tax/income/agi/la_federal_retirement_benefits.py | 2 +- .../gov/states/la/tax/income/agi/la_other_subtractions.py | 2 +- .../gov/states/la/tax/income/agi/la_total_subtractions.py | 2 +- .../la/tax/income/credits/la_refundable_priority_2_credit.py | 2 +- .../variables/gov/states/la/tax/income/la_exemptions.py | 3 +-- 6 files changed, 6 insertions(+), 7 deletions(-) diff --git a/fiscalsim_us/parameters/gov/states/la/tax/income/credits/refundable_p2/childcare_expense_limit.yaml b/fiscalsim_us/parameters/gov/states/la/tax/income/credits/refundable_p2/childcare_expense_limit.yaml index 3bced9ae1..28f377ee6 100644 --- a/fiscalsim_us/parameters/gov/states/la/tax/income/credits/refundable_p2/childcare_expense_limit.yaml +++ b/fiscalsim_us/parameters/gov/states/la/tax/income/credits/refundable_p2/childcare_expense_limit.yaml @@ -13,7 +13,7 @@ brackets: 2021-01-01: 2 amount: 2021-01-01: 16_000 - 2021-01-01: 6_000 + 2022-01-01: 6_000 metadata: type: single_amount diff --git a/fiscalsim_us/variables/gov/states/la/tax/income/agi/la_federal_retirement_benefits.py b/fiscalsim_us/variables/gov/states/la/tax/income/agi/la_federal_retirement_benefits.py index afb05c049..18a57d9b2 100644 --- a/fiscalsim_us/variables/gov/states/la/tax/income/agi/la_federal_retirement_benefits.py +++ b/fiscalsim_us/variables/gov/states/la/tax/income/agi/la_federal_retirement_benefits.py @@ -2,7 +2,7 @@ class la_federal_retirement_benefits(Variable): - "Amount of retirement benefits recieved from a + """Amount of retirement benefits recieved from a Federal Retirement System """ value_type = float diff --git a/fiscalsim_us/variables/gov/states/la/tax/income/agi/la_other_subtractions.py b/fiscalsim_us/variables/gov/states/la/tax/income/agi/la_other_subtractions.py index 71d170650..b0351f9f0 100644 --- a/fiscalsim_us/variables/gov/states/la/tax/income/agi/la_other_subtractions.py +++ b/fiscalsim_us/variables/gov/states/la/tax/income/agi/la_other_subtractions.py @@ -37,4 +37,4 @@ class la_other_subtractions(Variable): unit = USD definition_period = YEAR defined_for = StateCode.LA - adds = gov.states.la.tax.income.agi.subtractions.sources + adds = "gov.states.la.tax.income.agi.subtractions.sources" diff --git a/fiscalsim_us/variables/gov/states/la/tax/income/agi/la_total_subtractions.py b/fiscalsim_us/variables/gov/states/la/tax/income/agi/la_total_subtractions.py index 2fb20bb78..bc232fd49 100644 --- a/fiscalsim_us/variables/gov/states/la/tax/income/agi/la_total_subtractions.py +++ b/fiscalsim_us/variables/gov/states/la/tax/income/agi/la_total_subtractions.py @@ -12,4 +12,4 @@ class la_total_subtractions(Variable): unit = USD definition_period = YEAR defined_for = StateCode.LA - adds = gov.states.la.tax.income.agi.subtractions.sources + adds = "gov.states.la.tax.income.agi.subtractions.sources" diff --git a/fiscalsim_us/variables/gov/states/la/tax/income/credits/la_refundable_priority_2_credit.py b/fiscalsim_us/variables/gov/states/la/tax/income/credits/la_refundable_priority_2_credit.py index 669ac4203..c1c21cddc 100644 --- a/fiscalsim_us/variables/gov/states/la/tax/income/credits/la_refundable_priority_2_credit.py +++ b/fiscalsim_us/variables/gov/states/la/tax/income/credits/la_refundable_priority_2_credit.py @@ -12,5 +12,5 @@ class la_refundable_priority_2_credits(Variable): "https://revenue.louisiana.gov/TaxForms/IT540WEB(2022)%20F%20D2.pdf", "https://revenue.louisiana.gov/TaxForms/IT540iWEB(2022)D1.pdf" ) - adds = gov.states.la.tax.income.credits.nonrefundable_p2.sources + adds = "gov.states.la.tax.income.credits.nonrefundable_p2.sources" diff --git a/fiscalsim_us/variables/gov/states/la/tax/income/la_exemptions.py b/fiscalsim_us/variables/gov/states/la/tax/income/la_exemptions.py index 8ce240ebe..59c06ef25 100644 --- a/fiscalsim_us/variables/gov/states/la/tax/income/la_exemptions.py +++ b/fiscalsim_us/variables/gov/states/la/tax/income/la_exemptions.py @@ -20,8 +20,7 @@ def formula(tax_unit, period, parameters): filing_status == statuses.SEPARATE ) - dependents = tax_unit("tax_unit_dependents", period) - - where(joint_separate, 1, 0) + dependents = tax_unit("tax_unit_dependents", period) - where(joint_separate, 1, 0) aged_blind = tax_unit("aged_blind_count", period) personal_multiplier = where(joint_separate, 2, 1) From 49fdd7803d3aabf52d7842e18d3b31f4f2d73939 Mon Sep 17 00:00:00 2001 From: mitchellpound Date: Sat, 5 Aug 2023 16:47:30 -0600 Subject: [PATCH 09/19] Started tests and bug fixes --- .../tax/income/agi/subtractions/sources.yaml | 2 +- .../gov/states/la/tax/income/la_tax.yaml | 29 +++++++++++++++++++ .../la/tax/income/la_taxable_income.yaml | 9 ++++++ .../tax/income/agi/la_other_subtractions.py | 1 - .../income/credits/la_refundable_childcare.py | 6 ++-- .../income/credits/la_refundable_credits.py | 16 +++++----- .../la_refundable_priority_2_credit.py | 3 +- .../states/la/tax/income/la_taxable_income.py | 5 +++- .../gov/states/tax/income/state_income_tax.py | 1 + ...te_income_tax_before_refundable_credits.py | 1 + .../household_refundable_tax_credits.py | 1 + ...household_tax_before_refundable_credits.py | 1 + 12 files changed, 60 insertions(+), 15 deletions(-) create mode 100644 fiscalsim_us/tests/policy/baseline/gov/states/la/tax/income/la_tax.yaml create mode 100644 fiscalsim_us/tests/policy/baseline/gov/states/la/tax/income/la_taxable_income.yaml diff --git a/fiscalsim_us/parameters/gov/states/la/tax/income/agi/subtractions/sources.yaml b/fiscalsim_us/parameters/gov/states/la/tax/income/agi/subtractions/sources.yaml index c3671ce7a..a8eaa6aa1 100644 --- a/fiscalsim_us/parameters/gov/states/la/tax/income/agi/subtractions/sources.yaml +++ b/fiscalsim_us/parameters/gov/states/la/tax/income/agi/subtractions/sources.yaml @@ -1,7 +1,7 @@ description: Louisiana allows these subtractions (exemptions) from taxable income values: 2021-01-01: - - us_govt_income + - us_govt_interest - tax_unit_taxable_social_security - la_state_employee_retirement_benefits - la_state_teacher_retirement_benefits diff --git a/fiscalsim_us/tests/policy/baseline/gov/states/la/tax/income/la_tax.yaml b/fiscalsim_us/tests/policy/baseline/gov/states/la/tax/income/la_tax.yaml new file mode 100644 index 000000000..5421aa6e0 --- /dev/null +++ b/fiscalsim_us/tests/policy/baseline/gov/states/la/tax/income/la_tax.yaml @@ -0,0 +1,29 @@ +- name: LA tax no income + period: 2021 + absolute_error_margin: 0 + input: + filing_status: SINGLE + la_taxable_income: 0 + state_code: LA + output: + la_income_tax: 0.0 + +- name: LA first tax bracket + period: 2021 + absolute_error_margin: 0 + input: + filing_status: SINGLE + la_taxable_income: 12_000 + state_code: LA + output: + la_income_tax: 222 + +- name: LA all tax brackets + period: 2021 + absolute_error_margin: 0 + input: + filing_status: SINGLE + la_taxable_income: 100_000 + state_code: LA + output: + la_income_tax: 3668.75 diff --git a/fiscalsim_us/tests/policy/baseline/gov/states/la/tax/income/la_taxable_income.yaml b/fiscalsim_us/tests/policy/baseline/gov/states/la/tax/income/la_taxable_income.yaml new file mode 100644 index 000000000..e82adbb45 --- /dev/null +++ b/fiscalsim_us/tests/policy/baseline/gov/states/la/tax/income/la_taxable_income.yaml @@ -0,0 +1,9 @@ +- name: LA taxable income not itemizing + period: 2021 + absolute_error_margin: 0 + input: + filing_status: SINGLE + state_code: LA + adjusted_gross_income: 100_000 + output: + la_taxable_income: 100_000 diff --git a/fiscalsim_us/variables/gov/states/la/tax/income/agi/la_other_subtractions.py b/fiscalsim_us/variables/gov/states/la/tax/income/agi/la_other_subtractions.py index b0351f9f0..d57232529 100644 --- a/fiscalsim_us/variables/gov/states/la/tax/income/agi/la_other_subtractions.py +++ b/fiscalsim_us/variables/gov/states/la/tax/income/agi/la_other_subtractions.py @@ -37,4 +37,3 @@ class la_other_subtractions(Variable): unit = USD definition_period = YEAR defined_for = StateCode.LA - adds = "gov.states.la.tax.income.agi.subtractions.sources" diff --git a/fiscalsim_us/variables/gov/states/la/tax/income/credits/la_refundable_childcare.py b/fiscalsim_us/variables/gov/states/la/tax/income/credits/la_refundable_childcare.py index 160f03d40..1db7b788e 100644 --- a/fiscalsim_us/variables/gov/states/la/tax/income/credits/la_refundable_childcare.py +++ b/fiscalsim_us/variables/gov/states/la/tax/income/credits/la_refundable_childcare.py @@ -20,18 +20,18 @@ def formula(tax_unit, period, parameters): earned_income = tax_unit("tax_unit_earned_income", period) childcare_expenses = tax_unit("tax_unit_childcare_expenses", period) - # check for eligible children + # check for eligible children person = tax_unit.members dependent = person("is_tax_unit_dependent", period) age = person("age", period) child = age < p.childcare_child_age_limit eligible = dependent & child - eligible_children = tax_unit.sum(eligible_child) + eligible_children = tax_unit.sum(eligible) max_expense = p.childcare_expense_limit.calc(eligible_children) expense = min_(childcare_expenses, max_expense) - # line 6 of worksheet + # line 6 of worksheet credit = min_(expense, earned_income) income_mult = p.childcare_income_mult.calc(agi) diff --git a/fiscalsim_us/variables/gov/states/la/tax/income/credits/la_refundable_credits.py b/fiscalsim_us/variables/gov/states/la/tax/income/credits/la_refundable_credits.py index 9192e0316..25ef05e9c 100644 --- a/fiscalsim_us/variables/gov/states/la/tax/income/credits/la_refundable_credits.py +++ b/fiscalsim_us/variables/gov/states/la/tax/income/credits/la_refundable_credits.py @@ -19,14 +19,16 @@ def formula(tax_unit, period, parameters): # line 18 - floor at 0 since the priority 3 credits are nonrefundable tax_afer_p_2_credits = max_( - 0, - tax_unit("la_income_tax_before_refundable_credits", period) - priority_2_refund + 0, + tax_unit("la_income_tax_before_refundable_credits", period) - priority_2_refund ) priority_3_nonrefund_amount = tax_unit("la_nonrefundable_priority_3_credits", period) - - priority_3_nonrefund_add = max_(tax_afer_p_2_credits, priority_3_nonrefund_amount) - priority_4_refund = tax_unit("la_refundable_priority_4_credits", tax_unit) - - return priority_3_eligible + priority_3_nonrefund_add + priority_4_refund + # either refund the rest of the tax liability (leftover from p2) + # or refund the total amount of p3 credits, whichever is less + priority_3_nonrefund_add = min_(tax_afer_p_2_credits, priority_3_nonrefund_amount) + + priority_4_refund = tax_unit("la_refundable_priority_4_credits", period) + + return priority_2_refund + priority_3_nonrefund_add + priority_4_refund diff --git a/fiscalsim_us/variables/gov/states/la/tax/income/credits/la_refundable_priority_2_credit.py b/fiscalsim_us/variables/gov/states/la/tax/income/credits/la_refundable_priority_2_credit.py index c1c21cddc..9ce2310a3 100644 --- a/fiscalsim_us/variables/gov/states/la/tax/income/credits/la_refundable_priority_2_credit.py +++ b/fiscalsim_us/variables/gov/states/la/tax/income/credits/la_refundable_priority_2_credit.py @@ -12,5 +12,4 @@ class la_refundable_priority_2_credits(Variable): "https://revenue.louisiana.gov/TaxForms/IT540WEB(2022)%20F%20D2.pdf", "https://revenue.louisiana.gov/TaxForms/IT540iWEB(2022)D1.pdf" ) - adds = "gov.states.la.tax.income.credits.nonrefundable_p2.sources" - + adds = "gov.states.la.tax.income.credits.refundable_p2.sources" diff --git a/fiscalsim_us/variables/gov/states/la/tax/income/la_taxable_income.py b/fiscalsim_us/variables/gov/states/la/tax/income/la_taxable_income.py index c424bd97f..f52e2d357 100644 --- a/fiscalsim_us/variables/gov/states/la/tax/income/la_taxable_income.py +++ b/fiscalsim_us/variables/gov/states/la/tax/income/la_taxable_income.py @@ -19,10 +19,13 @@ def formula(tax_unit, period, parameters): la_agi = add(tax_unit, period, ADDS) - add(tax_unit, period, SUBTRACTS) + # LA allows tax units to subtract from income any portion of federal + # medical expense deductions that is more than the standard deduction filing_status = tax_unit("fiscalsim_us", period) + itemizing = tax_unit("tax_unit_itemizes", period) std_deduct = parameters.gov.ird.deductions.standard.amount[filing_status] medical_deduct = tax_unit("medical_expense_deduction", period) - excess_fed_deduct = max_(0, medical_deduct - std_deduct) + excess_fed_deduct = max_(0, itemizing * (medical_deduct - std_deduct)) return max_(0, la_agi - excess_fed_deduct) diff --git a/fiscalsim_us/variables/gov/states/tax/income/state_income_tax.py b/fiscalsim_us/variables/gov/states/tax/income/state_income_tax.py index 66bb988a6..cbd654601 100644 --- a/fiscalsim_us/variables/gov/states/tax/income/state_income_tax.py +++ b/fiscalsim_us/variables/gov/states/tax/income/state_income_tax.py @@ -12,6 +12,7 @@ class state_income_tax(Variable): "ca_income_tax", "il_income_tax", "ks_income_tax", + "la_income_tax", "ma_income_tax", "md_income_tax", "mn_income_tax", diff --git a/fiscalsim_us/variables/gov/states/tax/income/state_income_tax_before_refundable_credits.py b/fiscalsim_us/variables/gov/states/tax/income/state_income_tax_before_refundable_credits.py index b722872ce..0e2a7876b 100644 --- a/fiscalsim_us/variables/gov/states/tax/income/state_income_tax_before_refundable_credits.py +++ b/fiscalsim_us/variables/gov/states/tax/income/state_income_tax_before_refundable_credits.py @@ -10,6 +10,7 @@ class state_income_tax_before_refundable_credits(Variable): adds = [ "il_total_tax", "ks_income_tax_before_refundable_credits", + "la_income_tax_before_refundable_credits", "ma_income_tax_before_refundable_credits", "md_income_tax_before_refundable_credits", "mn_income_tax_before_refundable_credits", diff --git a/fiscalsim_us/variables/household/income/household/household_refundable_tax_credits.py b/fiscalsim_us/variables/household/income/household/household_refundable_tax_credits.py index cff758f82..14ad6240f 100644 --- a/fiscalsim_us/variables/household/income/household/household_refundable_tax_credits.py +++ b/fiscalsim_us/variables/household/income/household/household_refundable_tax_credits.py @@ -12,6 +12,7 @@ class household_refundable_tax_credits(Variable): "ca_refundable_credits", # California. "il_refundable_credits", # Illinois. "ks_refundable_credits", # Kansas. + "la_refundable_credits", # Louisianna "ma_refundable_credits", # Massachusetts. "md_refundable_credits", # Maryland. "mn_refundable_credits", # Minnesota. diff --git a/fiscalsim_us/variables/household/income/household/household_tax_before_refundable_credits.py b/fiscalsim_us/variables/household/income/household/household_tax_before_refundable_credits.py index 7aa335bc4..ce5d967f8 100644 --- a/fiscalsim_us/variables/household/income/household/household_tax_before_refundable_credits.py +++ b/fiscalsim_us/variables/household/income/household/household_tax_before_refundable_credits.py @@ -15,6 +15,7 @@ class household_tax_before_refundable_credits(Variable): "ca_income_tax_before_refundable_credits", "il_total_tax", "ks_income_tax_before_refundable_credits", + "la_income_tax_before_refundable_credits", "ma_income_tax_before_refundable_credits", "md_income_tax_before_refundable_credits", "mn_income_tax_before_refundable_credits", From 7c93614511bbd565a7c756e277a7a0400cbbc66d Mon Sep 17 00:00:00 2001 From: mitchellpound Date: Sun, 6 Aug 2023 16:36:09 -0600 Subject: [PATCH 10/19] Bug fixes to let LA code run. --- .../baseline/gov/states/la/tax/income/la_taxable_income.yaml | 2 +- .../variables/gov/states/la/tax/income/la_taxable_income.py | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/fiscalsim_us/tests/policy/baseline/gov/states/la/tax/income/la_taxable_income.yaml b/fiscalsim_us/tests/policy/baseline/gov/states/la/tax/income/la_taxable_income.yaml index e82adbb45..67eef8e2c 100644 --- a/fiscalsim_us/tests/policy/baseline/gov/states/la/tax/income/la_taxable_income.yaml +++ b/fiscalsim_us/tests/policy/baseline/gov/states/la/tax/income/la_taxable_income.yaml @@ -4,6 +4,6 @@ input: filing_status: SINGLE state_code: LA - adjusted_gross_income: 100_000 + adjusted_gross_income: 100 output: la_taxable_income: 100_000 diff --git a/fiscalsim_us/variables/gov/states/la/tax/income/la_taxable_income.py b/fiscalsim_us/variables/gov/states/la/tax/income/la_taxable_income.py index f52e2d357..99e48692a 100644 --- a/fiscalsim_us/variables/gov/states/la/tax/income/la_taxable_income.py +++ b/fiscalsim_us/variables/gov/states/la/tax/income/la_taxable_income.py @@ -21,9 +21,9 @@ def formula(tax_unit, period, parameters): # LA allows tax units to subtract from income any portion of federal # medical expense deductions that is more than the standard deduction - filing_status = tax_unit("fiscalsim_us", period) + filing_status = tax_unit("filing_status", period) itemizing = tax_unit("tax_unit_itemizes", period) - std_deduct = parameters.gov.ird.deductions.standard.amount[filing_status] + std_deduct = parameters(period).gov.irs.deductions.standard.amount[filing_status] medical_deduct = tax_unit("medical_expense_deduction", period) excess_fed_deduct = max_(0, itemizing * (medical_deduct - std_deduct)) From 17f052bc9ee838cff9b4fa0f985d3f3b1a14bc8b Mon Sep 17 00:00:00 2001 From: mitchellpound Date: Mon, 7 Aug 2023 13:30:53 -0600 Subject: [PATCH 11/19] Added tests for taxable income and exemptions --- .../states/la/tax/income/la_exemptions.yaml | 53 ++++++++++++++ .../la/tax/income/la_taxable_income.yaml | 72 +++++++++++++++++-- .../gov/states/la/tax/income/la_exemptions.py | 2 +- .../states/la/tax/income/la_taxable_income.py | 5 +- 4 files changed, 125 insertions(+), 7 deletions(-) create mode 100644 fiscalsim_us/tests/policy/baseline/gov/states/la/tax/income/la_exemptions.yaml diff --git a/fiscalsim_us/tests/policy/baseline/gov/states/la/tax/income/la_exemptions.yaml b/fiscalsim_us/tests/policy/baseline/gov/states/la/tax/income/la_exemptions.yaml new file mode 100644 index 000000000..c1be95e0a --- /dev/null +++ b/fiscalsim_us/tests/policy/baseline/gov/states/la/tax/income/la_exemptions.yaml @@ -0,0 +1,53 @@ +- name: LA exemption single no dependents + period: 2022 + absolute_error_margin: 0 + input: + filing_status: SINGLE + state_code: LA + adjusted_gross_income: 100_000 + output: + la_exemptions: 4_500 + +- name: LA exemption joint no dependents + period: 2022 + absolute_error_margin: 0 + input: + filing_status: JOINT + state_code: LA + adjusted_gross_income: 100_000 + output: + la_exemptions: 9_000 + +- name: LA exemption joint 2 dependents + period: 2022 + absolute_error_margin: 0 + input: + filing_status: JOINT + state_code: LA + tax_unit_dependents: 2 + adjusted_gross_income: 100_000 + output: + la_exemptions: 11_000 + +- name: LA exemption single 2 dependents + period: 2022 + absolute_error_margin: 0 + input: + filing_status: SINGLE + state_code: LA + tax_unit_dependents: 2 + adjusted_gross_income: 100_000 + output: + la_exemptions: 6_500 + +- name: LA exemption single 1 dependents and 1 65+/blind + period: 2022 + absolute_error_margin: 0 + input: + filing_status: SINGLE + state_code: LA + tax_unit_dependents: 1 + aged_blind_count: 1 + adjusted_gross_income: 100_000 + output: + la_exemptions: 6_500 diff --git a/fiscalsim_us/tests/policy/baseline/gov/states/la/tax/income/la_taxable_income.yaml b/fiscalsim_us/tests/policy/baseline/gov/states/la/tax/income/la_taxable_income.yaml index 67eef8e2c..9e6235f9e 100644 --- a/fiscalsim_us/tests/policy/baseline/gov/states/la/tax/income/la_taxable_income.yaml +++ b/fiscalsim_us/tests/policy/baseline/gov/states/la/tax/income/la_taxable_income.yaml @@ -1,9 +1,73 @@ -- name: LA taxable income not itemizing - period: 2021 +- name: LA taxable income not itemizing with additions + period: 2022 absolute_error_margin: 0 input: + tax_unit_itemizes: false filing_status: SINGLE state_code: LA - adjusted_gross_income: 100 + adjusted_gross_income: 100_000 + la_total_additions: 1_000 + la_exemptions: 0 output: - la_taxable_income: 100_000 + la_taxable_income: 101_000 + +- name: LA taxable income not itemizing with subtractions + period: 2022 + absolute_error_margin: 0 + input: + tax_unit_itemizes: false + filing_status: SINGLE + state_code: LA + adjusted_gross_income: 100_000 + la_total_subtractions: 1_000 + la_exemptions: 2_000 + output: + la_taxable_income: 97_000 + +- name: LA taxable income not itemizing additions and exemptions + period: 2022 + absolute_error_margin: 0 + input: + tax_unit_itemizes: false + filing_status: SINGLE + state_code: LA + adjusted_gross_income: 100_000 + la_total_additions: 1_000 + output: + la_taxable_income: 96_500 + +- name: LA taxable income not itemizing additions and exemptions joint + period: 2022 + absolute_error_margin: 0 + input: + tax_unit_itemizes: false + filing_status: JOINT + state_code: LA + adjusted_gross_income: 100_000 + la_total_additions: 1_000 + output: + la_taxable_income: 92_000 + +- name: LA taxable income itemizing additions and exemptions joint + period: 2022 + absolute_error_margin: 0 + input: + tax_unit_itemizes: true + filing_status: JOINT + state_code: LA + adjusted_gross_income: 100_000 + la_total_additions: 1_000 + output: + la_taxable_income: 92_000 + +- name: LA taxable income itemizing single with medical expenses + period: 2022 + absolute_error_margin: 0 + input: + tax_unit_itemizes: true + filing_status: SINGLE + state_code: LA + adjusted_gross_income: 100_000 + medical_expense_deduction: 14_950 + output: + la_taxable_income: 93_500 diff --git a/fiscalsim_us/variables/gov/states/la/tax/income/la_exemptions.py b/fiscalsim_us/variables/gov/states/la/tax/income/la_exemptions.py index 59c06ef25..c320d1725 100644 --- a/fiscalsim_us/variables/gov/states/la/tax/income/la_exemptions.py +++ b/fiscalsim_us/variables/gov/states/la/tax/income/la_exemptions.py @@ -20,7 +20,7 @@ def formula(tax_unit, period, parameters): filing_status == statuses.SEPARATE ) - dependents = tax_unit("tax_unit_dependents", period) - where(joint_separate, 1, 0) + dependents = tax_unit("tax_unit_dependents", period) aged_blind = tax_unit("aged_blind_count", period) personal_multiplier = where(joint_separate, 2, 1) diff --git a/fiscalsim_us/variables/gov/states/la/tax/income/la_taxable_income.py b/fiscalsim_us/variables/gov/states/la/tax/income/la_taxable_income.py index 99e48692a..bd90de720 100644 --- a/fiscalsim_us/variables/gov/states/la/tax/income/la_taxable_income.py +++ b/fiscalsim_us/variables/gov/states/la/tax/income/la_taxable_income.py @@ -26,6 +26,7 @@ def formula(tax_unit, period, parameters): std_deduct = parameters(period).gov.irs.deductions.standard.amount[filing_status] medical_deduct = tax_unit("medical_expense_deduction", period) - excess_fed_deduct = max_(0, itemizing * (medical_deduct - std_deduct)) + excess_fed_deduct = max_(0, medical_deduct - std_deduct) - return max_(0, la_agi - excess_fed_deduct) +# return max_(0, la_agi - excess_fed_deduct) + return where(itemizing, la_agi - excess_fed_deduct, la_agi) From 477201e4965de0ae17f6f8e843aa36b7057ae6c6 Mon Sep 17 00:00:00 2001 From: mitchellpound Date: Mon, 7 Aug 2023 14:16:40 -0600 Subject: [PATCH 12/19] Added tests for the different credit priorities --- .../la/tax/income/la_credit_priorities.yaml | 105 ++++++++++++++++++ 1 file changed, 105 insertions(+) create mode 100644 fiscalsim_us/tests/policy/baseline/gov/states/la/tax/income/la_credit_priorities.yaml diff --git a/fiscalsim_us/tests/policy/baseline/gov/states/la/tax/income/la_credit_priorities.yaml b/fiscalsim_us/tests/policy/baseline/gov/states/la/tax/income/la_credit_priorities.yaml new file mode 100644 index 000000000..86a4105cc --- /dev/null +++ b/fiscalsim_us/tests/policy/baseline/gov/states/la/tax/income/la_credit_priorities.yaml @@ -0,0 +1,105 @@ +- name: LA income tax p1 credit + period: 2022 + absolute_error_margin: 0 + input: + filing_status: SINGLE + la_income_tax_before_credits: 5_000 + la_nonrefundable_credits: 1_000 + state_code: LA + output: + la_income_tax: 4_000 + +- name: LA income tax p1 credit nonrefundable + period: 2022 + absolute_error_margin: 0 + input: + filing_status: SINGLE + la_income_tax_before_credits: 5_000 + la_nonrefundable_credits: 6_000 + state_code: LA + output: + la_income_tax: 0 + +- name: LA p2 credit nonrefundable + period: 2022 + absolute_error_margin: 0 + input: + filing_status: SINGLE + la_income_tax_before_credits: 5_000 + la_refundable_priority_2_credits: 6_000 + state_code: LA + output: + la_income_tax: -1_000 + +- name: LA p1 and p2 credits mixed + period: 2022 + absolute_error_margin: 0 + input: + filing_status: SINGLE + la_income_tax_before_credits: 5_000 + la_nonrefundable_credits: 3_000 + la_refundable_priority_2_credits: 6_000 + state_code: LA + output: + la_income_tax: -4_000 + +- name: LA p1 and p2 credits mixed extra nonrefundable + period: 2022 + absolute_error_margin: 0 + input: + filing_status: SINGLE + la_income_tax_before_credits: 5_000 + la_nonrefundable_credits: 6_000 + la_refundable_priority_2_credits: 6_000 + state_code: LA + output: + la_income_tax: -6_000 + +- name: LA p2 and p3 credits + period: 2022 + absolute_error_margin: 0 + input: + filing_status: SINGLE + la_income_tax_before_credits: 5_000 + la_refundable_priority_2_credits: 6_000 + la_nonrefundable_priority_3_credits: 1_000 + state_code: LA + output: + la_income_tax: -1_000 + +- name: LA p2 and p3 credits + period: 2022 + absolute_error_margin: 0 + input: + filing_status: SINGLE + la_income_tax_before_credits: 5_000 + la_refundable_priority_2_credits: 3_000 + la_nonrefundable_priority_3_credits: 1_000 + state_code: LA + output: + la_income_tax: 1_000 + +- name: LA p2 and p3 credits + period: 2021 + absolute_error_margin: 0 + input: + filing_status: SINGLE + la_income_tax_before_credits: 5_000 + la_refundable_priority_2_credits: 3_000 + la_nonrefundable_priority_3_credits: 3_000 + state_code: LA + output: + la_income_tax: 0 + +- name: LA p2, p3, and p4 credits + period: 2022 + absolute_error_margin: 0 + input: + filing_status: SINGLE + la_income_tax_before_credits: 5_000 + la_refundable_priority_2_credits: 3_000 + la_nonrefundable_priority_3_credits: 1_000 + la_refundable_priority_4_credits: 2_000 + state_code: LA + output: + la_income_tax: -1_000 From b66173bef195b0ef334f91910e34cf85459cd907 Mon Sep 17 00:00:00 2001 From: mitchellpound Date: Mon, 7 Aug 2023 19:52:45 -0600 Subject: [PATCH 13/19] Created tests for LA credits --- .../la/tax/income/la_credit_priorities.yaml | 6 +- .../gov/states/la/tax/income/la_credits.yaml | 131 ++++++++++++++++++ .../income/credits/la_refundable_childcare.py | 19 ++- ...py => la_refundable_priority_2_credits.py} | 0 4 files changed, 150 insertions(+), 6 deletions(-) create mode 100644 fiscalsim_us/tests/policy/baseline/gov/states/la/tax/income/la_credits.yaml rename fiscalsim_us/variables/gov/states/la/tax/income/credits/{la_refundable_priority_2_credit.py => la_refundable_priority_2_credits.py} (100%) diff --git a/fiscalsim_us/tests/policy/baseline/gov/states/la/tax/income/la_credit_priorities.yaml b/fiscalsim_us/tests/policy/baseline/gov/states/la/tax/income/la_credit_priorities.yaml index 86a4105cc..b4ac44409 100644 --- a/fiscalsim_us/tests/policy/baseline/gov/states/la/tax/income/la_credit_priorities.yaml +++ b/fiscalsim_us/tests/policy/baseline/gov/states/la/tax/income/la_credit_priorities.yaml @@ -55,7 +55,7 @@ output: la_income_tax: -6_000 -- name: LA p2 and p3 credits +- name: LA p2 and p3 credits refund period: 2022 absolute_error_margin: 0 input: @@ -67,7 +67,7 @@ output: la_income_tax: -1_000 -- name: LA p2 and p3 credits +- name: LA p2 and p3 credits no refund period: 2022 absolute_error_margin: 0 input: @@ -79,7 +79,7 @@ output: la_income_tax: 1_000 -- name: LA p2 and p3 credits +- name: LA p2 and p3 credits extra p3 period: 2021 absolute_error_margin: 0 input: diff --git a/fiscalsim_us/tests/policy/baseline/gov/states/la/tax/income/la_credits.yaml b/fiscalsim_us/tests/policy/baseline/gov/states/la/tax/income/la_credits.yaml new file mode 100644 index 000000000..8ede182d4 --- /dev/null +++ b/fiscalsim_us/tests/policy/baseline/gov/states/la/tax/income/la_credits.yaml @@ -0,0 +1,131 @@ +- name: Federal EITC of $500 and no qualifying children, LA EITC should be $25 + period: 2022 + absolute_error_margin: 0 + input: + earned_income_tax_credit: 500 + state_code: LA + output: + la_eitc: 25 + +- name: LA refundable childcare credit over $25,000 income limit + period: 2022 + absolute_error_margin: 0 + input: + people: + person1: + age: 33 + employment_income: 100_000 + person2: + age: 35 + employment_income: 50_000 + dependent1: + age: 8 + is_tax_unit_dependent: true + tax_units: + tax_unit: + members: [person1, person2, dependent1] + tax_unit_childcare_expenses: 1_000 + filing_status: JOINT + households: + household: + members: [person1, person2, dependent1] + state_code: LA + output: + la_refundable_childcare: 0 + +- name: LA refundable childcare credit one child + period: 2022 + absolute_error_margin: 0 + input: + people: + person1: + age: 33 + employment_income: 10_000 + person2: + age: 35 + employment_income: 10_000 + dependent1: + age: 8 + is_tax_unit_dependent: true + tax_units: + tax_unit: + members: [person1, person2, dependent1] + tax_unit_childcare_expenses: 4_000 + filing_status: JOINT + households: + household: + members: [person1, person2, dependent1] + state_code: LA + output: + la_refundable_childcare: 480 + +- name: LA refundable childcare credit 3 children + period: 2022 + absolute_error_margin: 0 + input: + people: + person1: + age: 33 + employment_income: 10_000 + person2: + age: 35 + employment_income: 10_000 + dependent1: + age: 8 + is_tax_unit_dependent: true + dependent2: + age: 9 + is_tax_unit_dependent: true + dependent3: + age: 7 + is_tax_unit_dependent: true + tax_units: + tax_unit: + members: [person1, person2, dependent1, dependent2, dependent3] + tax_unit_childcare_expenses: 7_000 + filing_status: JOINT + households: + household: + members: [person1, person2, dependent1, dependent2, dependent3] + state_code: LA + output: + la_refundable_childcare: 960 + +- name: LA refundable childcare credit one child spouse income below expenses + period: 2022 + absolute_error_margin: 0 + input: + people: + person1: + age: 33 + employment_income: 18_000 + person2: + age: 35 + employment_income: 2_000 + dependent1: + age: 8 + is_tax_unit_dependent: true + tax_units: + tax_unit: + members: [person1, person2, dependent1] + tax_unit_childcare_expenses: 4_000 + filing_status: JOINT + households: + household: + members: [person1, person2, dependent1] + state_code: LA + output: + la_refundable_childcare: 320 + + +- name: Addition of p2 refundable credits + period: 2022 + absolute_error_margin: 0 + input: + state_code: LA + earned_income_tax_credit: 500 + la_refundable_school_ready: 100 + la_refundable_childcare: 200 + la_other_refundable_p2: 100 + output: + la_refundable_priority_2_credits: 425 diff --git a/fiscalsim_us/variables/gov/states/la/tax/income/credits/la_refundable_childcare.py b/fiscalsim_us/variables/gov/states/la/tax/income/credits/la_refundable_childcare.py index 1db7b788e..6991a011e 100644 --- a/fiscalsim_us/variables/gov/states/la/tax/income/credits/la_refundable_childcare.py +++ b/fiscalsim_us/variables/gov/states/la/tax/income/credits/la_refundable_childcare.py @@ -17,11 +17,24 @@ def formula(tax_unit, period, parameters): p = parameters(period).gov.states.la.tax.income.credits.refundable_p2 agi = tax_unit("adjusted_gross_income", period) - earned_income = tax_unit("tax_unit_earned_income", period) + person = tax_unit.members + dependent = person("is_tax_unit_dependent", period) + earned_income = max_(0, person("earned", period)) + filing_status = tax_unit("filing_status", period) + non_dependent_income = ~dependent * earned_income + + # if tax unit is joint then pick the minimum of the non-dependent + # earned incomes, else pick the (only) max non-dependent income + tax_unit_min_income = where( + filing_status == filing_status.possible_values.JOINT, + tax_unit.sum(non_dependent_income) - tax_unit.max(non_dependent_income), + tax_unit.max(non_dependent_income) + ) + + # earned_income = tax_unit("tax_unit_earned_income", period) childcare_expenses = tax_unit("tax_unit_childcare_expenses", period) # check for eligible children - person = tax_unit.members dependent = person("is_tax_unit_dependent", period) age = person("age", period) child = age < p.childcare_child_age_limit @@ -32,7 +45,7 @@ def formula(tax_unit, period, parameters): expense = min_(childcare_expenses, max_expense) # line 6 of worksheet - credit = min_(expense, earned_income) + credit = min_(expense, tax_unit_min_income) income_mult = p.childcare_income_mult.calc(agi) mult = p.refundable_childcare_mult diff --git a/fiscalsim_us/variables/gov/states/la/tax/income/credits/la_refundable_priority_2_credit.py b/fiscalsim_us/variables/gov/states/la/tax/income/credits/la_refundable_priority_2_credits.py similarity index 100% rename from fiscalsim_us/variables/gov/states/la/tax/income/credits/la_refundable_priority_2_credit.py rename to fiscalsim_us/variables/gov/states/la/tax/income/credits/la_refundable_priority_2_credits.py From 3d2e81a73cc83396a7796580711e1fa325754937 Mon Sep 17 00:00:00 2001 From: mitchellpound Date: Mon, 7 Aug 2023 20:10:03 -0600 Subject: [PATCH 14/19] Added tests for LA subtractions from income --- .../la/tax/income/la_agi_subtractions.yaml | 16 ++++++++++++++++ .../la/tax/income/agi/la_total_subtractions.py | 1 - 2 files changed, 16 insertions(+), 1 deletion(-) create mode 100644 fiscalsim_us/tests/policy/baseline/gov/states/la/tax/income/la_agi_subtractions.yaml diff --git a/fiscalsim_us/tests/policy/baseline/gov/states/la/tax/income/la_agi_subtractions.yaml b/fiscalsim_us/tests/policy/baseline/gov/states/la/tax/income/la_agi_subtractions.yaml new file mode 100644 index 000000000..b3ef8033c --- /dev/null +++ b/fiscalsim_us/tests/policy/baseline/gov/states/la/tax/income/la_agi_subtractions.yaml @@ -0,0 +1,16 @@ +- name: LA subtractions from income + period: 2021 + absolute_error_margin: 0 + input: + filing_status: SINGLE + adjusted_gross_income: 100_000 + us_govt_interest: 1_000 + tax_unit_taxable_social_security: 1_000 + la_state_employee_retirement_benefits: 1_000 + la_state_teacher_retirement_benefits: 1_000 + la_federal_retirement_benefits: 1_000 + la_other_subtractions: 1_000 + la_exemptions: 0 + state_code: LA + output: + la_taxable_income: 94_000 diff --git a/fiscalsim_us/variables/gov/states/la/tax/income/agi/la_total_subtractions.py b/fiscalsim_us/variables/gov/states/la/tax/income/agi/la_total_subtractions.py index bc232fd49..c531afc19 100644 --- a/fiscalsim_us/variables/gov/states/la/tax/income/agi/la_total_subtractions.py +++ b/fiscalsim_us/variables/gov/states/la/tax/income/agi/la_total_subtractions.py @@ -5,7 +5,6 @@ class la_total_subtractions(Variable): """ Subtractions from louisiana adjusted income """ - value_type = float entity = TaxUnit label = "Louisiana total subtractions from AGI" From 970206dbfd5e4574986d8f9cd0d44ad408d6f47a Mon Sep 17 00:00:00 2001 From: mitchellpound Date: Mon, 7 Aug 2023 20:22:24 -0600 Subject: [PATCH 15/19] Reformated files --- .../agi/la_federal_retirement_benefits.py | 3 ++- .../tax/income/agi/la_other_subtractions.py | 2 +- .../tax/income/agi/la_total_subtractions.py | 1 + .../states/la/tax/income/credits/la_eitc.py | 3 +-- .../credits/la_nonrefundable_credits.py | 2 +- .../la_nonrefundable_priority_3_credits.py | 6 ++--- .../income/credits/la_other_refundable_p2.py | 10 ++++---- .../income/credits/la_refundable_childcare.py | 10 ++++---- .../income/credits/la_refundable_credits.py | 24 ++++++++++++------- .../la_refundable_priority_2_credits.py | 2 +- .../la_refundable_priority_4_credits.py | 7 +++--- .../credits/la_refundable_school_ready.py | 3 ++- .../gov/states/la/tax/income/la_exemptions.py | 15 ++++++------ .../gov/states/la/tax/income/la_income_tax.py | 1 - .../states/la/tax/income/la_taxable_income.py | 8 ++++--- 15 files changed, 55 insertions(+), 42 deletions(-) diff --git a/fiscalsim_us/variables/gov/states/la/tax/income/agi/la_federal_retirement_benefits.py b/fiscalsim_us/variables/gov/states/la/tax/income/agi/la_federal_retirement_benefits.py index 18a57d9b2..54d7ac2e2 100644 --- a/fiscalsim_us/variables/gov/states/la/tax/income/agi/la_federal_retirement_benefits.py +++ b/fiscalsim_us/variables/gov/states/la/tax/income/agi/la_federal_retirement_benefits.py @@ -2,9 +2,10 @@ class la_federal_retirement_benefits(Variable): - """Amount of retirement benefits recieved from a + """Amount of retirement benefits recieved from a Federal Retirement System """ + value_type = float entity = TaxUnit label = "Louisiana state teacher retirement benefits" diff --git a/fiscalsim_us/variables/gov/states/la/tax/income/agi/la_other_subtractions.py b/fiscalsim_us/variables/gov/states/la/tax/income/agi/la_other_subtractions.py index d57232529..71dc412f2 100644 --- a/fiscalsim_us/variables/gov/states/la/tax/income/agi/la_other_subtractions.py +++ b/fiscalsim_us/variables/gov/states/la/tax/income/agi/la_other_subtractions.py @@ -4,7 +4,7 @@ class la_other_subtractions(Variable): """ Other subtractions from louisiana taxable income. - These include the following exemptions from income with + These include the following exemptions from income with the associated codes: 05E – Other Retirement Benefits 06E – Annual Retirement Income Exemption for Taxpayers 65 diff --git a/fiscalsim_us/variables/gov/states/la/tax/income/agi/la_total_subtractions.py b/fiscalsim_us/variables/gov/states/la/tax/income/agi/la_total_subtractions.py index c531afc19..bc232fd49 100644 --- a/fiscalsim_us/variables/gov/states/la/tax/income/agi/la_total_subtractions.py +++ b/fiscalsim_us/variables/gov/states/la/tax/income/agi/la_total_subtractions.py @@ -5,6 +5,7 @@ class la_total_subtractions(Variable): """ Subtractions from louisiana adjusted income """ + value_type = float entity = TaxUnit label = "Louisiana total subtractions from AGI" diff --git a/fiscalsim_us/variables/gov/states/la/tax/income/credits/la_eitc.py b/fiscalsim_us/variables/gov/states/la/tax/income/credits/la_eitc.py index f472d8f12..bec22e05a 100644 --- a/fiscalsim_us/variables/gov/states/la/tax/income/credits/la_eitc.py +++ b/fiscalsim_us/variables/gov/states/la/tax/income/credits/la_eitc.py @@ -13,12 +13,11 @@ class la_eitc(Variable): definition_period = YEAR reference = ( "https://revenue.louisiana.gov/TaxForms/IT540WEB(2022)%20F%20D2.pdf", - "https://revenue.louisiana.gov/TaxForms/IT540iWEB(2022)D1.pdf" + "https://revenue.louisiana.gov/TaxForms/IT540iWEB(2022)D1.pdf", ) defined_for = StateCode.LA def formula(tax_unit, period, parameters): - federal_eitc = tax_unit("earned_income_tax_credit", period) p = parameters(period).gov.states.la.tax.income.credits.refundable_p2 diff --git a/fiscalsim_us/variables/gov/states/la/tax/income/credits/la_nonrefundable_credits.py b/fiscalsim_us/variables/gov/states/la/tax/income/credits/la_nonrefundable_credits.py index b219c7847..8db5fc9db 100644 --- a/fiscalsim_us/variables/gov/states/la/tax/income/credits/la_nonrefundable_credits.py +++ b/fiscalsim_us/variables/gov/states/la/tax/income/credits/la_nonrefundable_credits.py @@ -20,6 +20,6 @@ class la_nonrefundable_credits(Variable): definition_period = YEAR reference = ( "https://revenue.louisiana.gov/TaxForms/IT540WEB(2022)%20F%20D2.pdf", - "https://revenue.louisiana.gov/TaxForms/IT540iWEB(2022)D1.pdf" + "https://revenue.louisiana.gov/TaxForms/IT540iWEB(2022)D1.pdf", ) defined_for = StateCode.LA diff --git a/fiscalsim_us/variables/gov/states/la/tax/income/credits/la_nonrefundable_priority_3_credits.py b/fiscalsim_us/variables/gov/states/la/tax/income/credits/la_nonrefundable_priority_3_credits.py index 6b8021682..14e76e412 100644 --- a/fiscalsim_us/variables/gov/states/la/tax/income/credits/la_nonrefundable_priority_3_credits.py +++ b/fiscalsim_us/variables/gov/states/la/tax/income/credits/la_nonrefundable_priority_3_credits.py @@ -3,7 +3,7 @@ class la_nonrefundable_priority_3_credits(Variable): """ - Louisiana nonrefundable priority 3 credits + Louisiana nonrefundable priority 3 credits Form IT-540 line 20 These include the following credits with codes: 202 – Organ Donation @@ -43,6 +43,7 @@ class la_nonrefundable_priority_3_credits(Variable): 510 – Enterprise Zone 550 – Recycling Credit """ + value_type = float entity = TaxUnit label = "Louisiana nonrefundable priority 3 income tax credits" @@ -51,6 +52,5 @@ class la_nonrefundable_priority_3_credits(Variable): defined_for = StateCode.LA reference = ( "https://revenue.louisiana.gov/TaxForms/IT540WEB(2022)%20F%20D2.pdf", - "https://revenue.louisiana.gov/TaxForms/IT540iWEB(2022)D1.pdf" + "https://revenue.louisiana.gov/TaxForms/IT540iWEB(2022)D1.pdf", ) - diff --git a/fiscalsim_us/variables/gov/states/la/tax/income/credits/la_other_refundable_p2.py b/fiscalsim_us/variables/gov/states/la/tax/income/credits/la_other_refundable_p2.py index 26b0919a2..26ad2c650 100644 --- a/fiscalsim_us/variables/gov/states/la/tax/income/credits/la_other_refundable_p2.py +++ b/fiscalsim_us/variables/gov/states/la/tax/income/credits/la_other_refundable_p2.py @@ -3,8 +3,8 @@ class la_other_refundable_p2(Variable): """ - Other Louisiana refundable priority 2 credits listed - on Schedule F for IT-540. These credits include the + Other Louisiana refundable priority 2 credits listed + on Schedule F for IT-540. These credits include the following with codes: * 52F - Ad Valorem Offshore Vessels * 54F – Telephone Company Property @@ -15,7 +15,7 @@ class la_other_refundable_p2(Variable): * 62F – Musical and Theatrical Production * 65F – School Readiness Child Care Provider * 66F – School Readiness Child Care Directors and Staff - * 67F – School Readiness Business-Supported Child Care + * 67F – School Readiness Business-Supported Child Care * 68F – School Readiness Fees and Grants to Resource and Referral Agencies * 70F – Retention and Modernization @@ -24,6 +24,7 @@ class la_other_refundable_p2(Variable): * 77F – Funeral and Burial Expense for a Pregnancy-related Death * 80F – Other Refundable Credit """ + unit = USD value_type = float entity = TaxUnit @@ -33,6 +34,5 @@ class la_other_refundable_p2(Variable): defined_for = StateCode.LA reference = ( "https://revenue.louisiana.gov/TaxForms/IT540WEB(2022)%20F%20D2.pdf", - "https://revenue.louisiana.gov/TaxForms/IT540iWEB(2022)D1.pdf" + "https://revenue.louisiana.gov/TaxForms/IT540iWEB(2022)D1.pdf", ) - diff --git a/fiscalsim_us/variables/gov/states/la/tax/income/credits/la_refundable_childcare.py b/fiscalsim_us/variables/gov/states/la/tax/income/credits/la_refundable_childcare.py index 6991a011e..7fdf62160 100644 --- a/fiscalsim_us/variables/gov/states/la/tax/income/credits/la_refundable_childcare.py +++ b/fiscalsim_us/variables/gov/states/la/tax/income/credits/la_refundable_childcare.py @@ -10,11 +10,10 @@ class la_refundable_childcare(Variable): defined_for = StateCode.LA reference = ( "https://revenue.louisiana.gov/TaxForms/IT540WEB(2022)%20F%20D2.pdf", - "https://revenue.louisiana.gov/TaxForms/IT540iWEB(2022)D1.pdf" + "https://revenue.louisiana.gov/TaxForms/IT540iWEB(2022)D1.pdf", ) def formula(tax_unit, period, parameters): - p = parameters(period).gov.states.la.tax.income.credits.refundable_p2 agi = tax_unit("adjusted_gross_income", period) person = tax_unit.members @@ -27,9 +26,10 @@ def formula(tax_unit, period, parameters): # earned incomes, else pick the (only) max non-dependent income tax_unit_min_income = where( filing_status == filing_status.possible_values.JOINT, - tax_unit.sum(non_dependent_income) - tax_unit.max(non_dependent_income), - tax_unit.max(non_dependent_income) - ) + tax_unit.sum(non_dependent_income) + - tax_unit.max(non_dependent_income), + tax_unit.max(non_dependent_income), + ) # earned_income = tax_unit("tax_unit_earned_income", period) childcare_expenses = tax_unit("tax_unit_childcare_expenses", period) diff --git a/fiscalsim_us/variables/gov/states/la/tax/income/credits/la_refundable_credits.py b/fiscalsim_us/variables/gov/states/la/tax/income/credits/la_refundable_credits.py index 25ef05e9c..24da47116 100644 --- a/fiscalsim_us/variables/gov/states/la/tax/income/credits/la_refundable_credits.py +++ b/fiscalsim_us/variables/gov/states/la/tax/income/credits/la_refundable_credits.py @@ -10,25 +10,33 @@ class la_refundable_credits(Variable): defined_for = StateCode.LA reference = ( "https://revenue.louisiana.gov/TaxForms/IT540WEB(2022)%20F%20D2.pdf", - "https://revenue.louisiana.gov/TaxForms/IT540iWEB(2022)D1.pdf" + "https://revenue.louisiana.gov/TaxForms/IT540iWEB(2022)D1.pdf", ) def formula(tax_unit, period, parameters): + priority_2_refund = tax_unit( + "la_refundable_priority_2_credits", period + ) - priority_2_refund = tax_unit("la_refundable_priority_2_credits", period) - # line 18 - floor at 0 since the priority 3 credits are nonrefundable tax_afer_p_2_credits = max_( 0, - tax_unit("la_income_tax_before_refundable_credits", period) - priority_2_refund - ) + tax_unit("la_income_tax_before_refundable_credits", period) + - priority_2_refund, + ) - priority_3_nonrefund_amount = tax_unit("la_nonrefundable_priority_3_credits", period) + priority_3_nonrefund_amount = tax_unit( + "la_nonrefundable_priority_3_credits", period + ) # either refund the rest of the tax liability (leftover from p2) # or refund the total amount of p3 credits, whichever is less - priority_3_nonrefund_add = min_(tax_afer_p_2_credits, priority_3_nonrefund_amount) + priority_3_nonrefund_add = min_( + tax_afer_p_2_credits, priority_3_nonrefund_amount + ) - priority_4_refund = tax_unit("la_refundable_priority_4_credits", period) + priority_4_refund = tax_unit( + "la_refundable_priority_4_credits", period + ) return priority_2_refund + priority_3_nonrefund_add + priority_4_refund diff --git a/fiscalsim_us/variables/gov/states/la/tax/income/credits/la_refundable_priority_2_credits.py b/fiscalsim_us/variables/gov/states/la/tax/income/credits/la_refundable_priority_2_credits.py index 9ce2310a3..d79f12251 100644 --- a/fiscalsim_us/variables/gov/states/la/tax/income/credits/la_refundable_priority_2_credits.py +++ b/fiscalsim_us/variables/gov/states/la/tax/income/credits/la_refundable_priority_2_credits.py @@ -10,6 +10,6 @@ class la_refundable_priority_2_credits(Variable): defined_for = StateCode.LA reference = ( "https://revenue.louisiana.gov/TaxForms/IT540WEB(2022)%20F%20D2.pdf", - "https://revenue.louisiana.gov/TaxForms/IT540iWEB(2022)D1.pdf" + "https://revenue.louisiana.gov/TaxForms/IT540iWEB(2022)D1.pdf", ) adds = "gov.states.la.tax.income.credits.refundable_p2.sources" diff --git a/fiscalsim_us/variables/gov/states/la/tax/income/credits/la_refundable_priority_4_credits.py b/fiscalsim_us/variables/gov/states/la/tax/income/credits/la_refundable_priority_4_credits.py index 3ef88b605..2f7263d39 100644 --- a/fiscalsim_us/variables/gov/states/la/tax/income/credits/la_refundable_priority_4_credits.py +++ b/fiscalsim_us/variables/gov/states/la/tax/income/credits/la_refundable_priority_4_credits.py @@ -3,12 +3,13 @@ class la_refundable_priority_4_credits(Variable): """ - louisiana refundable priority 4 credits - Line 25 on Form IT-540. These credits include the + louisiana refundable priority 4 credits + Line 25 on Form IT-540. These credits include the following with codes: * 50F - Inventory Tax * 51F - Ad Valorem Natural Gas """ + value_type = float entity = TaxUnit label = "Louisiana refundable priority 4 income tax credits" @@ -17,5 +18,5 @@ class la_refundable_priority_4_credits(Variable): defined_for = StateCode.LA reference = ( "https://revenue.louisiana.gov/TaxForms/IT540WEB(2022)%20F%20D2.pdf", - "https://revenue.louisiana.gov/TaxForms/IT540iWEB(2022)D1.pdf" + "https://revenue.louisiana.gov/TaxForms/IT540iWEB(2022)D1.pdf", ) diff --git a/fiscalsim_us/variables/gov/states/la/tax/income/credits/la_refundable_school_ready.py b/fiscalsim_us/variables/gov/states/la/tax/income/credits/la_refundable_school_ready.py index 431656acb..d2902fa4b 100644 --- a/fiscalsim_us/variables/gov/states/la/tax/income/credits/la_refundable_school_ready.py +++ b/fiscalsim_us/variables/gov/states/la/tax/income/credits/la_refundable_school_ready.py @@ -6,6 +6,7 @@ class la_refundable_school_ready(Variable): louisiana refundable school readiness credit Line 14 on Form IT-540. """ + value_type = float entity = TaxUnit label = "Louisiana refundable priority 4 income tax credits" @@ -14,5 +15,5 @@ class la_refundable_school_ready(Variable): defined_for = StateCode.LA reference = ( "https://revenue.louisiana.gov/TaxForms/IT540WEB(2022)%20F%20D2.pdf", - "https://revenue.louisiana.gov/TaxForms/IT540iWEB(2022)D1.pdf" + "https://revenue.louisiana.gov/TaxForms/IT540iWEB(2022)D1.pdf", ) diff --git a/fiscalsim_us/variables/gov/states/la/tax/income/la_exemptions.py b/fiscalsim_us/variables/gov/states/la/tax/income/la_exemptions.py index c320d1725..071a01dc9 100644 --- a/fiscalsim_us/variables/gov/states/la/tax/income/la_exemptions.py +++ b/fiscalsim_us/variables/gov/states/la/tax/income/la_exemptions.py @@ -7,23 +7,24 @@ class la_exemptions(Variable): label = "Louisiana exemptions amount" unit = USD definition_period = YEAR - reference = ( - ) + reference = () defined_for = StateCode.LA def formula(tax_unit, period, parameters): - p = parameters(period).gov.states.la.tax.income.exemptions filing_status = tax_unit("filing_status", period) statuses = filing_status.possible_values joint_separate = (filing_status == statuses.JOINT) | ( filing_status == statuses.SEPARATE ) - + dependents = tax_unit("tax_unit_dependents", period) - aged_blind = tax_unit("aged_blind_count", period) + aged_blind = tax_unit("aged_blind_count", period) personal_multiplier = where(joint_separate, 2, 1) - n_extra = dependents + aged_blind + n_extra = dependents + aged_blind - return p.personal_amount * personal_multiplier + p.additional_amount * n_extra + return ( + p.personal_amount * personal_multiplier + + p.additional_amount * n_extra + ) diff --git a/fiscalsim_us/variables/gov/states/la/tax/income/la_income_tax.py b/fiscalsim_us/variables/gov/states/la/tax/income/la_income_tax.py index 63edfda8c..0ff502c54 100644 --- a/fiscalsim_us/variables/gov/states/la/tax/income/la_income_tax.py +++ b/fiscalsim_us/variables/gov/states/la/tax/income/la_income_tax.py @@ -14,4 +14,3 @@ class la_income_tax(Variable): defined_for = StateCode.LA adds = ["la_income_tax_before_refundable_credits"] subtracts = ["la_refundable_credits"] - diff --git a/fiscalsim_us/variables/gov/states/la/tax/income/la_taxable_income.py b/fiscalsim_us/variables/gov/states/la/tax/income/la_taxable_income.py index bd90de720..e4ac9f686 100644 --- a/fiscalsim_us/variables/gov/states/la/tax/income/la_taxable_income.py +++ b/fiscalsim_us/variables/gov/states/la/tax/income/la_taxable_income.py @@ -23,10 +23,12 @@ def formula(tax_unit, period, parameters): # medical expense deductions that is more than the standard deduction filing_status = tax_unit("filing_status", period) itemizing = tax_unit("tax_unit_itemizes", period) - std_deduct = parameters(period).gov.irs.deductions.standard.amount[filing_status] + std_deduct = parameters(period).gov.irs.deductions.standard.amount[ + filing_status + ] medical_deduct = tax_unit("medical_expense_deduction", period) - + excess_fed_deduct = max_(0, medical_deduct - std_deduct) -# return max_(0, la_agi - excess_fed_deduct) + # return max_(0, la_agi - excess_fed_deduct) return where(itemizing, la_agi - excess_fed_deduct, la_agi) From e93ec6968d724827e84a55588a7cae6dc8a62777 Mon Sep 17 00:00:00 2001 From: mitchellpound Date: Wed, 9 Aug 2023 23:16:53 -0600 Subject: [PATCH 16/19] Added nonrefundable childcare credit and tests --- .../above_threshold_max.yaml | 16 ++++ .../income_floor.yaml | 16 ++++ .../nonrefundable_child_care/income_mult.yaml | 29 +++++++ .../income_threshold.yaml | 16 ++++ .../credits/nonrefundable_p3/sources.yaml | 13 ++++ .../credits/refundable_p2/eitc_mult.yaml | 5 +- .../child_age_limit.yaml} | 2 +- .../expense_limit.yaml} | 0 .../income_mult.yaml} | 0 .../mult.yaml} | 0 .../income/exemptions/additional_amount.yaml | 4 +- .../income/exemptions/personal_amount.yaml | 4 +- .../tax/income/rates/head_of_household.yaml | 7 +- .../gov/states/la/tax/income/rates/joint.yaml | 6 +- .../states/la/tax/income/rates/separate.yaml | 6 +- .../states/la/tax/income/rates/single.yaml | 6 +- .../gov/states/la/tax/income/rates/widow.yaml | 6 +- .../gov/states/la/tax/income/la_credits.yaml | 35 +++++++++ .../states/la/tax/income/la_exemptions.yaml | 78 ++++++++++++++++--- .../gov/states/la/tax/income/la_tax.yaml | 6 +- .../credits/la_nonrefundable_childcare.py | 30 +++++++ .../la_nonrefundable_priority_3_credits.py | 43 +--------- .../credits/la_other_nonrefundable_p3.py | 56 +++++++++++++ .../income/credits/la_refundable_childcare.py | 10 +-- .../gov/states/la/tax/income/la_exemptions.py | 7 +- 25 files changed, 317 insertions(+), 84 deletions(-) create mode 100644 fiscalsim_us/parameters/gov/states/la/tax/income/credits/nonrefundable_p3/nonrefundable_child_care/above_threshold_max.yaml create mode 100644 fiscalsim_us/parameters/gov/states/la/tax/income/credits/nonrefundable_p3/nonrefundable_child_care/income_floor.yaml create mode 100644 fiscalsim_us/parameters/gov/states/la/tax/income/credits/nonrefundable_p3/nonrefundable_child_care/income_mult.yaml create mode 100644 fiscalsim_us/parameters/gov/states/la/tax/income/credits/nonrefundable_p3/nonrefundable_child_care/income_threshold.yaml create mode 100644 fiscalsim_us/parameters/gov/states/la/tax/income/credits/nonrefundable_p3/sources.yaml rename fiscalsim_us/parameters/gov/states/la/tax/income/credits/refundable_p2/{childcare_child_age_limit.yaml => refundable_child_care/child_age_limit.yaml} (87%) rename fiscalsim_us/parameters/gov/states/la/tax/income/credits/refundable_p2/{childcare_expense_limit.yaml => refundable_child_care/expense_limit.yaml} (100%) rename fiscalsim_us/parameters/gov/states/la/tax/income/credits/refundable_p2/{childcare_income_mult.yaml => refundable_child_care/income_mult.yaml} (100%) rename fiscalsim_us/parameters/gov/states/la/tax/income/credits/refundable_p2/{refundable_childcare_mult.yaml => refundable_child_care/mult.yaml} (100%) create mode 100644 fiscalsim_us/variables/gov/states/la/tax/income/credits/la_nonrefundable_childcare.py create mode 100644 fiscalsim_us/variables/gov/states/la/tax/income/credits/la_other_nonrefundable_p3.py diff --git a/fiscalsim_us/parameters/gov/states/la/tax/income/credits/nonrefundable_p3/nonrefundable_child_care/above_threshold_max.yaml b/fiscalsim_us/parameters/gov/states/la/tax/income/credits/nonrefundable_p3/nonrefundable_child_care/above_threshold_max.yaml new file mode 100644 index 000000000..a360caf11 --- /dev/null +++ b/fiscalsim_us/parameters/gov/states/la/tax/income/credits/nonrefundable_p3/nonrefundable_child_care/above_threshold_max.yaml @@ -0,0 +1,16 @@ +description: Louisiana limits its child and dependent care credit to this maximum amount for filers above the income threshold + +values: + 2006-01-01: 25 + +metadata: + period: year + unit: currency-USD + label: Louisiana nonrefundable child care credit max above income threshold + reference: + - title: §297.4. Reduction to tax due; certain child care expenses, part (A)(4) + href: http://legis.la.gov/Legis/Law.aspx?d=101769 + - title: 2022 Louisiana Resident Income Tax Return, page 16-2A + href: https://revenue.louisiana.gov/TaxForms/IT540WEB(2022)%20F%20D2.pdf + - title: 2021 Louisiana Resident Income Tax Return, page 16-2A + href: https://revenue.louisiana.gov/TaxForms/IT540WEB(2021)%20F.pdf \ No newline at end of file diff --git a/fiscalsim_us/parameters/gov/states/la/tax/income/credits/nonrefundable_p3/nonrefundable_child_care/income_floor.yaml b/fiscalsim_us/parameters/gov/states/la/tax/income/credits/nonrefundable_p3/nonrefundable_child_care/income_floor.yaml new file mode 100644 index 000000000..40a0fd447 --- /dev/null +++ b/fiscalsim_us/parameters/gov/states/la/tax/income/credits/nonrefundable_p3/nonrefundable_child_care/income_floor.yaml @@ -0,0 +1,16 @@ +description: Louisiana makes its child and dependent care credit refundable for incomes under the income floor using slightly different logic found in the la_refundable_childcare variable + +values: + 2006-01-01: 25_000 + +metadata: + period: year + unit: currency-USD + label: Louisiana non-refundable child care credit income floor + reference: + - title: §297.4. Reduction to tax due; certain child care expenses, part (B) + href: http://legis.la.gov/Legis/Law.aspx?d=101769 + - title: 2022 Louisiana Resident Income Tax Return, page 14,16 + href: https://revenue.louisiana.gov/TaxForms/IT540WEB(2022)%20F%20D2.pdf + - title: 2021 Louisiana Resident Income Tax Return, page 14,16 + href: https://revenue.louisiana.gov/TaxForms/IT540WEB(2021)%20F.pdf \ No newline at end of file diff --git a/fiscalsim_us/parameters/gov/states/la/tax/income/credits/nonrefundable_p3/nonrefundable_child_care/income_mult.yaml b/fiscalsim_us/parameters/gov/states/la/tax/income/credits/nonrefundable_p3/nonrefundable_child_care/income_mult.yaml new file mode 100644 index 000000000..5f87e67f2 --- /dev/null +++ b/fiscalsim_us/parameters/gov/states/la/tax/income/credits/nonrefundable_p3/nonrefundable_child_care/income_mult.yaml @@ -0,0 +1,29 @@ +description: Income multiplier for Louisiana non-refundable child care tax credit + +brackets: + - threshold: + 2006-01-01: 25_000 + amount: + 2006-01-01: 0.3 + - threshold: + 2006-01-01: 35_000 + amount: + 2006-01-01: 0.1 + - threshold: + 2006-01-01: 60_000 + amount: + 2006-01-01: 0.1 + +metadata: + type: single_amount + threshold_unit: currency-USD + amount_unit: /1 + period: year + label: Louisiana non-refundable child care credit income multiplier + reference: + - title: §297.4. Reduction to tax due; certain child care expenses, part (A)(2)-(4) + href: http://legis.la.gov/Legis/Law.aspx?d=101769 + - title: 2022 Louisiana Resident Income Tax Return + href: https://revenue.louisiana.gov/TaxForms/IT540WEB(2022)%20F%20D2.pdf#page=16 + - title: 2021 Louisiana Resident Income Tax Return + href: https://revenue.louisiana.gov/TaxForms/IT540WEB(2021)%20F.pdf#page=16 \ No newline at end of file diff --git a/fiscalsim_us/parameters/gov/states/la/tax/income/credits/nonrefundable_p3/nonrefundable_child_care/income_threshold.yaml b/fiscalsim_us/parameters/gov/states/la/tax/income/credits/nonrefundable_p3/nonrefundable_child_care/income_threshold.yaml new file mode 100644 index 000000000..0896804f5 --- /dev/null +++ b/fiscalsim_us/parameters/gov/states/la/tax/income/credits/nonrefundable_p3/nonrefundable_child_care/income_threshold.yaml @@ -0,0 +1,16 @@ +description: Louisiana limits the amount of the non-refundable child care credit for tax units with agi above this limit + +values: + 2006-01-01: 60_000 + +metadata: + period: year + unit: currency-USD + label: Louisiana non refundable child-care tax income threshold + reference: + - title: §297.4. Reduction to tax due; certain child care expenses, part (A)(4) + href: http://legis.la.gov/Legis/Law.aspx?d=101769 + - title: 2022 Louisiana Resident Income Tax Return, page 16-2A + href: https://revenue.louisiana.gov/TaxForms/IT540WEB(2022)%20F%20D2.pdf + - title: 2021 Louisiana Resident Income Tax Return, page 16-2A + href: https://revenue.louisiana.gov/TaxForms/IT540WEB(2021)%20F.pdf \ No newline at end of file diff --git a/fiscalsim_us/parameters/gov/states/la/tax/income/credits/nonrefundable_p3/sources.yaml b/fiscalsim_us/parameters/gov/states/la/tax/income/credits/nonrefundable_p3/sources.yaml new file mode 100644 index 000000000..42340a449 --- /dev/null +++ b/fiscalsim_us/parameters/gov/states/la/tax/income/credits/nonrefundable_p3/sources.yaml @@ -0,0 +1,13 @@ +description: Louisiana provides these non-refundable priority 3 tax credits. +values: + 2021-01-01: + - la_nonrefundable_childcare + - la_other_nonrefundable_p3 + +metadata: + unit: variable + label: Louisiana refundable priorty 3 tax credits + reference: + - title: Louisiana Form IT-540 Schedule J - Refundable credits + href: https://revenue.louisiana.gov/TaxForms/IT540iWEB(2022)D1.pdf + diff --git a/fiscalsim_us/parameters/gov/states/la/tax/income/credits/refundable_p2/eitc_mult.yaml b/fiscalsim_us/parameters/gov/states/la/tax/income/credits/refundable_p2/eitc_mult.yaml index 584469549..9acf147e6 100644 --- a/fiscalsim_us/parameters/gov/states/la/tax/income/credits/refundable_p2/eitc_mult.yaml +++ b/fiscalsim_us/parameters/gov/states/la/tax/income/credits/refundable_p2/eitc_mult.yaml @@ -1,12 +1,15 @@ description: Multiplier for the amount of the federal EITC that Louisiana allows taxfiliers for a refundable credit values: - 2021-01-01: .05 + 2018-01-01: 0.035 + 2019-01-01: 0.05 metadata: period: year unit: /1 label: Louisiana EITC multiplier reference: + - title: Louisiana legal code| RS 47:297.8, part (A) + href: https://www.legis.la.gov/legis/Law.aspx?d=453085 - title: Louisiana State Inncome Tax Form IT-540 2021 href: "https://revenue.louisiana.gov/TaxForms/IT540WEB(2021)%20F.pdf" - title: Louisiana State Inncome Tax Form IT-540 2022 diff --git a/fiscalsim_us/parameters/gov/states/la/tax/income/credits/refundable_p2/childcare_child_age_limit.yaml b/fiscalsim_us/parameters/gov/states/la/tax/income/credits/refundable_p2/refundable_child_care/child_age_limit.yaml similarity index 87% rename from fiscalsim_us/parameters/gov/states/la/tax/income/credits/refundable_p2/childcare_child_age_limit.yaml rename to fiscalsim_us/parameters/gov/states/la/tax/income/credits/refundable_p2/refundable_child_care/child_age_limit.yaml index 38153753a..c335db0bd 100644 --- a/fiscalsim_us/parameters/gov/states/la/tax/income/credits/refundable_p2/childcare_child_age_limit.yaml +++ b/fiscalsim_us/parameters/gov/states/la/tax/income/credits/refundable_p2/refundable_child_care/child_age_limit.yaml @@ -1,4 +1,4 @@ -description: Louisiana allows refundbale childcare credit for childcare expenses for children under this age limit +description: Louisiana allows refundable childcare credit for childcare expenses for children under this age limit values: 2021-01-01: 13 diff --git a/fiscalsim_us/parameters/gov/states/la/tax/income/credits/refundable_p2/childcare_expense_limit.yaml b/fiscalsim_us/parameters/gov/states/la/tax/income/credits/refundable_p2/refundable_child_care/expense_limit.yaml similarity index 100% rename from fiscalsim_us/parameters/gov/states/la/tax/income/credits/refundable_p2/childcare_expense_limit.yaml rename to fiscalsim_us/parameters/gov/states/la/tax/income/credits/refundable_p2/refundable_child_care/expense_limit.yaml diff --git a/fiscalsim_us/parameters/gov/states/la/tax/income/credits/refundable_p2/childcare_income_mult.yaml b/fiscalsim_us/parameters/gov/states/la/tax/income/credits/refundable_p2/refundable_child_care/income_mult.yaml similarity index 100% rename from fiscalsim_us/parameters/gov/states/la/tax/income/credits/refundable_p2/childcare_income_mult.yaml rename to fiscalsim_us/parameters/gov/states/la/tax/income/credits/refundable_p2/refundable_child_care/income_mult.yaml diff --git a/fiscalsim_us/parameters/gov/states/la/tax/income/credits/refundable_p2/refundable_childcare_mult.yaml b/fiscalsim_us/parameters/gov/states/la/tax/income/credits/refundable_p2/refundable_child_care/mult.yaml similarity index 100% rename from fiscalsim_us/parameters/gov/states/la/tax/income/credits/refundable_p2/refundable_childcare_mult.yaml rename to fiscalsim_us/parameters/gov/states/la/tax/income/credits/refundable_p2/refundable_child_care/mult.yaml diff --git a/fiscalsim_us/parameters/gov/states/la/tax/income/exemptions/additional_amount.yaml b/fiscalsim_us/parameters/gov/states/la/tax/income/exemptions/additional_amount.yaml index 10f7968f9..0c6c958a2 100644 --- a/fiscalsim_us/parameters/gov/states/la/tax/income/exemptions/additional_amount.yaml +++ b/fiscalsim_us/parameters/gov/states/la/tax/income/exemptions/additional_amount.yaml @@ -1,6 +1,6 @@ description: Louisiana allows this exemption from income for each additional exemption past the personal values: - 2021-01-01: 1000 + 2021-01-01: 1_000 metadata: period: year @@ -11,3 +11,5 @@ metadata: href: "https://revenue.louisiana.gov/TaxForms/IT540TT%20(2021).pdf" - title: Louisiana Resident Income Tax Return Tax Table 2022 href: "https://revenue.louisiana.gov/TaxForms/IT540(2022)%20Tax%20Table.pdf" + - title: Louisiana Laws Revised Statutes, Title 47 — Revenue and taxation, RS 47:294 — Personal exemptions and credit for dependents, B + href: https://www.legis.la.gov/legis/Law.aspx?d=101761 diff --git a/fiscalsim_us/parameters/gov/states/la/tax/income/exemptions/personal_amount.yaml b/fiscalsim_us/parameters/gov/states/la/tax/income/exemptions/personal_amount.yaml index dec41e570..70202c06f 100644 --- a/fiscalsim_us/parameters/gov/states/la/tax/income/exemptions/personal_amount.yaml +++ b/fiscalsim_us/parameters/gov/states/la/tax/income/exemptions/personal_amount.yaml @@ -1,6 +1,6 @@ description: Louisiana allows this personal exemption from income values: - 2021-01-01: 4_500 + 1983-01-01: 4_500 metadata: period: year @@ -11,3 +11,5 @@ metadata: href: "https://revenue.louisiana.gov/TaxForms/IT540TT%20(2021).pdf" - title: Louisiana Resident Income Tax Return Tax Table 2022 href: "https://revenue.louisiana.gov/TaxForms/IT540(2022)%20Tax%20Table.pdf" + - title: Louisiana Laws Revised Statutes, Title 47 — Revenue and taxation, RS 47:294 — Personal exemptions and credit for dependents, A + href: https://www.legis.la.gov/legis/Law.aspx?d=101761 diff --git a/fiscalsim_us/parameters/gov/states/la/tax/income/rates/head_of_household.yaml b/fiscalsim_us/parameters/gov/states/la/tax/income/rates/head_of_household.yaml index 32d05f48b..b570d6da9 100644 --- a/fiscalsim_us/parameters/gov/states/la/tax/income/rates/head_of_household.yaml +++ b/fiscalsim_us/parameters/gov/states/la/tax/income/rates/head_of_household.yaml @@ -4,18 +4,17 @@ brackets: 2009-01-01: 0 rate: 2009-01-01: 0.02 - 2021-01-01: 0.0185 + 2022-01-01: 0.0185 - threshold: 2009-01-01: 12_500 rate: 2009-01-01: 0.04 - 2021-01-01: 0.035 + 2022-01-01: 0.0315 - threshold: 2009-01-01: 50_000 rate: 2009-01-01: 0.06 - 2021-01-01: 0.0425 - + 2022-01-01: 0.0425 metadata: type: marginal_rate threshold_unit: currency-USD diff --git a/fiscalsim_us/parameters/gov/states/la/tax/income/rates/joint.yaml b/fiscalsim_us/parameters/gov/states/la/tax/income/rates/joint.yaml index ae41cab65..9ac266af6 100644 --- a/fiscalsim_us/parameters/gov/states/la/tax/income/rates/joint.yaml +++ b/fiscalsim_us/parameters/gov/states/la/tax/income/rates/joint.yaml @@ -4,17 +4,17 @@ brackets: 2009-01-01: 0 rate: 2009-01-01: 0.02 - 2021-01-01: 0.0185 + 2022-01-01: 0.0185 - threshold: 2009-01-01: 25_000 rate: 2009-01-01: 0.04 - 2021-01-01: 0.035 + 2022-01-01: 0.035 - threshold: 2009-01-01: 100_000 rate: 2009-01-01: 0.06 - 2021-01-01: 0.0425 + 2022-01-01: 0.0425 metadata: type: marginal_rate diff --git a/fiscalsim_us/parameters/gov/states/la/tax/income/rates/separate.yaml b/fiscalsim_us/parameters/gov/states/la/tax/income/rates/separate.yaml index 86d5757f8..0b7662231 100644 --- a/fiscalsim_us/parameters/gov/states/la/tax/income/rates/separate.yaml +++ b/fiscalsim_us/parameters/gov/states/la/tax/income/rates/separate.yaml @@ -4,17 +4,17 @@ brackets: 2009-01-01: 0 rate: 2009-01-01: 0.02 - 2021-01-01: 0.0185 + 2022-01-01: 0.0185 - threshold: 2009-01-01: 12_500 rate: 2009-01-01: 0.04 - 2021-01-01: 0.035 + 2022-01-01: 0.035 - threshold: 2009-01-01: 50_000 rate: 2009-01-01: 0.06 - 2021-01-01: 0.0425 + 2022-01-01: 0.0425 metadata: type: marginal_rate diff --git a/fiscalsim_us/parameters/gov/states/la/tax/income/rates/single.yaml b/fiscalsim_us/parameters/gov/states/la/tax/income/rates/single.yaml index 9f71c5a44..b700ade98 100644 --- a/fiscalsim_us/parameters/gov/states/la/tax/income/rates/single.yaml +++ b/fiscalsim_us/parameters/gov/states/la/tax/income/rates/single.yaml @@ -4,17 +4,17 @@ brackets: 2009-01-01: 0 rate: 2009-01-01: 0.02 - 2021-01-01: 0.0185 + 2022-01-01: 0.0185 - threshold: 2009-01-01: 12_500 rate: 2009-01-01: 0.04 - 2021-01-01: 0.035 + 2022-01-01: 0.035 - threshold: 2009-01-01: 50_000 rate: 2009-01-01: 0.06 - 2021-01-01: 0.0425 + 2022-01-01: 0.0425 metadata: type: marginal_rate diff --git a/fiscalsim_us/parameters/gov/states/la/tax/income/rates/widow.yaml b/fiscalsim_us/parameters/gov/states/la/tax/income/rates/widow.yaml index 774c990a3..1b0a14103 100644 --- a/fiscalsim_us/parameters/gov/states/la/tax/income/rates/widow.yaml +++ b/fiscalsim_us/parameters/gov/states/la/tax/income/rates/widow.yaml @@ -4,17 +4,17 @@ brackets: 2009-01-01: 0 rate: 2009-01-01: 0.02 - 2021-01-01: 0.0185 + 2022-01-01: 0.0185 - threshold: 2009-01-01: 25_000 rate: 2009-01-01: 0.04 - 2021-01-01: 0.035 + 2022-01-01: 0.035 - threshold: 2009-01-01: 100_000 rate: 2009-01-01: 0.06 - 2021-01-01: 0.0425 + 2022-01-01: 0.0425 metadata: type: marginal_rate diff --git a/fiscalsim_us/tests/policy/baseline/gov/states/la/tax/income/la_credits.yaml b/fiscalsim_us/tests/policy/baseline/gov/states/la/tax/income/la_credits.yaml index 8ede182d4..8dcfe0cac 100644 --- a/fiscalsim_us/tests/policy/baseline/gov/states/la/tax/income/la_credits.yaml +++ b/fiscalsim_us/tests/policy/baseline/gov/states/la/tax/income/la_credits.yaml @@ -117,6 +117,41 @@ output: la_refundable_childcare: 320 +- name: LA nonrefundable child care credit below income floor ($0 nonrefundable) + period: 2022 + input: + adjusted_gross_income: 23_000 + cdcc: 2_000 + state_code: LA + output: + la_nonrefundable_childcare: 0 + +- name: LA nonrefundable child care credit + period: 2022 + input: + adjusted_gross_income: 30_000 + cdcc: 2_000 + state_code: LA + output: + la_nonrefundable_childcare: 600 + +- name: LA nonrefundable child care credit above income threshold + period: 2022 + input: + adjusted_gross_income: 60_001 + cdcc: 200 + state_code: LA + output: + la_nonrefundable_childcare: 20 + +- name: LA nonrefundable child care credit above income threshold with credit limit + period: 2022 + input: + adjusted_gross_income: 60_001 + cdcc: 1000 + state_code: LA + output: + la_nonrefundable_childcare: 25 - name: Addition of p2 refundable credits period: 2022 diff --git a/fiscalsim_us/tests/policy/baseline/gov/states/la/tax/income/la_exemptions.yaml b/fiscalsim_us/tests/policy/baseline/gov/states/la/tax/income/la_exemptions.yaml index c1be95e0a..605cde711 100644 --- a/fiscalsim_us/tests/policy/baseline/gov/states/la/tax/income/la_exemptions.yaml +++ b/fiscalsim_us/tests/policy/baseline/gov/states/la/tax/income/la_exemptions.yaml @@ -1,24 +1,36 @@ -- name: LA exemption single no dependents +- name: Single filer gets $4500 exemption. period: 2022 - absolute_error_margin: 0 input: - filing_status: SINGLE state_code: LA - adjusted_gross_income: 100_000 + filing_status: SINGLE output: la_exemptions: 4_500 -- name: LA exemption joint no dependents +- name: Joint filer gets $9,000 exemption. period: 2022 - absolute_error_margin: 0 input: + state_code: LA filing_status: JOINT + output: + la_exemptions: 9_000 + +- name: Head of household filer gets $9,000 exemption. + period: 2022 + input: state_code: LA - adjusted_gross_income: 100_000 + filing_status: HEAD_OF_HOUSEHOLD output: la_exemptions: 9_000 -- name: LA exemption joint 2 dependents +- name: Separate filer gets $4500 exemption. + period: 2022 + input: + state_code: LA + filing_status: SEPARATE + output: + la_exemptions: 4_500 + +- name: Joint 2 dependents gets $11,000 exemption period: 2022 absolute_error_margin: 0 input: @@ -29,7 +41,7 @@ output: la_exemptions: 11_000 -- name: LA exemption single 2 dependents +- name: Single 2 dependents gets $6_500 exemption period: 2022 absolute_error_margin: 0 input: @@ -40,7 +52,7 @@ output: la_exemptions: 6_500 -- name: LA exemption single 1 dependents and 1 65+/blind +- name: Single 1 dependents and 1 65+/blind gets $6,500 exemption period: 2022 absolute_error_margin: 0 input: @@ -51,3 +63,49 @@ adjusted_gross_income: 100_000 output: la_exemptions: 6_500 + +- name: 1 Blind not aged gets $10,000 exemption + period: 2021 + input: + people: + person1: + age: 64 + is_tax_unit_head: 1 + is_blind: 1 + person2: + age: 64 + is_tax_unit_spouse: 1 + is_blind: 0 + tax_units: + tax_unit: + members: [person1, person2] + filing_status: JOINT + households: + household: + members: [person1, person2] + state_code: LA + output: + la_exemptions: 10_000 + +- name: Non blind not aged gets $9,000 exemption + period: 2021 + input: + people: + person1: + age: 64 + is_tax_unit_head: 1 + is_blind: 0 + person2: + age: 64 + is_tax_unit_spouse: 1 + is_blind: 0 + tax_units: + tax_unit: + members: [person1, person2] + filing_status: JOINT + households: + household: + members: [person1, person2] + state_code: LA + output: + la_exemptions: 9_000 \ No newline at end of file diff --git a/fiscalsim_us/tests/policy/baseline/gov/states/la/tax/income/la_tax.yaml b/fiscalsim_us/tests/policy/baseline/gov/states/la/tax/income/la_tax.yaml index 5421aa6e0..e2cf1c7ac 100644 --- a/fiscalsim_us/tests/policy/baseline/gov/states/la/tax/income/la_tax.yaml +++ b/fiscalsim_us/tests/policy/baseline/gov/states/la/tax/income/la_tax.yaml @@ -1,5 +1,5 @@ - name: LA tax no income - period: 2021 + period: 2022 absolute_error_margin: 0 input: filing_status: SINGLE @@ -9,7 +9,7 @@ la_income_tax: 0.0 - name: LA first tax bracket - period: 2021 + period: 2022 absolute_error_margin: 0 input: filing_status: SINGLE @@ -19,7 +19,7 @@ la_income_tax: 222 - name: LA all tax brackets - period: 2021 + period: 2022 absolute_error_margin: 0 input: filing_status: SINGLE diff --git a/fiscalsim_us/variables/gov/states/la/tax/income/credits/la_nonrefundable_childcare.py b/fiscalsim_us/variables/gov/states/la/tax/income/credits/la_nonrefundable_childcare.py new file mode 100644 index 000000000..dc451bc06 --- /dev/null +++ b/fiscalsim_us/variables/gov/states/la/tax/income/credits/la_nonrefundable_childcare.py @@ -0,0 +1,30 @@ +from fiscalsim_us.model_api import * + + +class la_nonrefundable_childcare(Variable): + value_type = float + entity = TaxUnit + label = "Louisiana refundable childcare credits" + unit = USD + definition_period = YEAR + defined_for = StateCode.LA + reference = ( + "https://revenue.louisiana.gov/TaxForms/IT540WEB(2022)%20F%20D2.pdf", + "https://revenue.louisiana.gov/TaxForms/IT540iWEB(2022)D1.pdf", + ) + + def formula(tax_unit, period, parameters): + p = parameters(period).gov.states.la.tax.income.credits.nonrefundable_p3.nonrefundable_child_care + agi = tax_unit("adjusted_gross_income", period) + fed_cdcc = tax_unit("cdcc", period) + + # for agi under income floor can use the refundable credit + nonrefundable = agi > p.income_floor + fed_cdcc = fed_cdcc * nonrefundable + + income_mult = p.income_mult.calc(agi) + credit = fed_cdcc * income_mult + + # for agi over the threshold the credit is the minimum of + # fed_cdcc * income_mult and the limit for above the threshold + return where(agi > p.income_threshold, min(credit, p.above_threshold_max), credit) diff --git a/fiscalsim_us/variables/gov/states/la/tax/income/credits/la_nonrefundable_priority_3_credits.py b/fiscalsim_us/variables/gov/states/la/tax/income/credits/la_nonrefundable_priority_3_credits.py index 14e76e412..75a4f4d7f 100644 --- a/fiscalsim_us/variables/gov/states/la/tax/income/credits/la_nonrefundable_priority_3_credits.py +++ b/fiscalsim_us/variables/gov/states/la/tax/income/credits/la_nonrefundable_priority_3_credits.py @@ -2,48 +2,6 @@ class la_nonrefundable_priority_3_credits(Variable): - """ - Louisiana nonrefundable priority 3 credits - Form IT-540 line 20 - These include the following credits with codes: - 202 – Organ Donation - 208 – Previously Unemployed - 221 – Owner of Accessible and Barrier-free Home – - 224 – New Jobs Credit - 228 – Eligible Re-entrants – - 236 – Apprenticeship (2007) - 251 – Motion Picture Investment - 252 – Research and Development - 253 – Historic Structures - 254 – Digital Interactive Media - 257 – Capital Company - 258 – LA Community Development Financial Institution (LCDFI) - 259 – New Markets - 261 – Motion Picture Infrastructure - 262 – Angel Investor - 300 – Biomed/University Research - 305 – Tax Equalization - 310 – Manufacturing Establishment - 412 – Refund by Utilities - 424 – Donation to School Tuition Organization - 454 – QMC Music Job Creation Credit - 457 – Neighborhood Assistance - 458 – Research and Development - 459 – Ports of Louisiana Import Export Cargo - 460 – LA Import - 461 – LA Work Opportunity - 462 – Youth Jobs - 463 – Apprenticeship (2022) - 464 – Donation to Qualified Foster Care Charitable Organization - 500 – Inventory Tax Credit Carried Forward and ITEP - 502 – Ad Valorem Natural Gas Credit Carried Forward - 504 – Atchafalaya Trace - 506 – Cane River Heritage - 508 – Ports of Louisiana Investor - 510 – Enterprise Zone - 550 – Recycling Credit - """ - value_type = float entity = TaxUnit label = "Louisiana nonrefundable priority 3 income tax credits" @@ -54,3 +12,4 @@ class la_nonrefundable_priority_3_credits(Variable): "https://revenue.louisiana.gov/TaxForms/IT540WEB(2022)%20F%20D2.pdf", "https://revenue.louisiana.gov/TaxForms/IT540iWEB(2022)D1.pdf", ) + adds = "gov.states.la.tax.income.credits.nonrefundable_p3.sources" \ No newline at end of file diff --git a/fiscalsim_us/variables/gov/states/la/tax/income/credits/la_other_nonrefundable_p3.py b/fiscalsim_us/variables/gov/states/la/tax/income/credits/la_other_nonrefundable_p3.py new file mode 100644 index 000000000..0eab749be --- /dev/null +++ b/fiscalsim_us/variables/gov/states/la/tax/income/credits/la_other_nonrefundable_p3.py @@ -0,0 +1,56 @@ +from fiscalsim_us.model_api import * + + +class la_other_nonrefundable_p3(Variable): + """ + Louisiana nonrefundable priority 3 credits not yet implimented as separate variables + Form IT-540 line 20 + These include the following credits with codes: + 202 – Organ Donation + 208 – Previously Unemployed + 221 – Owner of Accessible and Barrier-free Home – + 224 – New Jobs Credit + 228 – Eligible Re-entrants – + 236 – Apprenticeship (2007) + 251 – Motion Picture Investment + 252 – Research and Development + 253 – Historic Structures + 254 – Digital Interactive Media + 257 – Capital Company + 258 – LA Community Development Financial Institution (LCDFI) + 259 – New Markets + 261 – Motion Picture Infrastructure + 262 – Angel Investor + 300 – Biomed/University Research + 305 – Tax Equalization + 310 – Manufacturing Establishment + 412 – Refund by Utilities + 424 – Donation to School Tuition Organization + 454 – QMC Music Job Creation Credit + 457 – Neighborhood Assistance + 458 – Research and Development + 459 – Ports of Louisiana Import Export Cargo + 460 – LA Import + 461 – LA Work Opportunity + 462 – Youth Jobs + 463 – Apprenticeship (2022) + 464 – Donation to Qualified Foster Care Charitable Organization + 500 – Inventory Tax Credit Carried Forward and ITEP + 502 – Ad Valorem Natural Gas Credit Carried Forward + 504 – Atchafalaya Trace + 506 – Cane River Heritage + 508 – Ports of Louisiana Investor + 510 – Enterprise Zone + 550 – Recycling Credit + """ + + value_type = float + entity = TaxUnit + label = "Louisiana nonrefundable priority 3 income tax credits" + unit = USD + definition_period = YEAR + defined_for = StateCode.LA + reference = ( + "https://revenue.louisiana.gov/TaxForms/IT540WEB(2022)%20F%20D2.pdf", + "https://revenue.louisiana.gov/TaxForms/IT540iWEB(2022)D1.pdf", + ) \ No newline at end of file diff --git a/fiscalsim_us/variables/gov/states/la/tax/income/credits/la_refundable_childcare.py b/fiscalsim_us/variables/gov/states/la/tax/income/credits/la_refundable_childcare.py index 7fdf62160..60bf47316 100644 --- a/fiscalsim_us/variables/gov/states/la/tax/income/credits/la_refundable_childcare.py +++ b/fiscalsim_us/variables/gov/states/la/tax/income/credits/la_refundable_childcare.py @@ -14,7 +14,7 @@ class la_refundable_childcare(Variable): ) def formula(tax_unit, period, parameters): - p = parameters(period).gov.states.la.tax.income.credits.refundable_p2 + p = parameters(period).gov.states.la.tax.income.credits.refundable_p2.refundable_child_care agi = tax_unit("adjusted_gross_income", period) person = tax_unit.members dependent = person("is_tax_unit_dependent", period) @@ -37,17 +37,17 @@ def formula(tax_unit, period, parameters): # check for eligible children dependent = person("is_tax_unit_dependent", period) age = person("age", period) - child = age < p.childcare_child_age_limit + child = age < p.child_age_limit eligible = dependent & child eligible_children = tax_unit.sum(eligible) - max_expense = p.childcare_expense_limit.calc(eligible_children) + max_expense = p.expense_limit.calc(eligible_children) expense = min_(childcare_expenses, max_expense) # line 6 of worksheet credit = min_(expense, tax_unit_min_income) - income_mult = p.childcare_income_mult.calc(agi) - mult = p.refundable_childcare_mult + income_mult = p.income_mult.calc(agi) + mult = p.mult return credit * income_mult * mult diff --git a/fiscalsim_us/variables/gov/states/la/tax/income/la_exemptions.py b/fiscalsim_us/variables/gov/states/la/tax/income/la_exemptions.py index 071a01dc9..23cfc4767 100644 --- a/fiscalsim_us/variables/gov/states/la/tax/income/la_exemptions.py +++ b/fiscalsim_us/variables/gov/states/la/tax/income/la_exemptions.py @@ -14,14 +14,13 @@ def formula(tax_unit, period, parameters): p = parameters(period).gov.states.la.tax.income.exemptions filing_status = tax_unit("filing_status", period) statuses = filing_status.possible_values - joint_separate = (filing_status == statuses.JOINT) | ( - filing_status == statuses.SEPARATE - ) + single_separate = (filing_status == statuses.SINGLE) | ( + filing_status == statuses.SEPARATE) dependents = tax_unit("tax_unit_dependents", period) aged_blind = tax_unit("aged_blind_count", period) - personal_multiplier = where(joint_separate, 2, 1) + personal_multiplier = where(single_separate, 1, 2) n_extra = dependents + aged_blind return ( From 749a66143df07b72e3cdc4ae659beeb4d9bc80e1 Mon Sep 17 00:00:00 2001 From: mitchellpound Date: Thu, 10 Aug 2023 10:31:47 -0600 Subject: [PATCH 17/19] Simplified la_refundable_childcare variable --- .../income/credits/la_refundable_childcare.py | 18 ++---------------- 1 file changed, 2 insertions(+), 16 deletions(-) diff --git a/fiscalsim_us/variables/gov/states/la/tax/income/credits/la_refundable_childcare.py b/fiscalsim_us/variables/gov/states/la/tax/income/credits/la_refundable_childcare.py index 60bf47316..6d9624a25 100644 --- a/fiscalsim_us/variables/gov/states/la/tax/income/credits/la_refundable_childcare.py +++ b/fiscalsim_us/variables/gov/states/la/tax/income/credits/la_refundable_childcare.py @@ -16,25 +16,10 @@ class la_refundable_childcare(Variable): def formula(tax_unit, period, parameters): p = parameters(period).gov.states.la.tax.income.credits.refundable_p2.refundable_child_care agi = tax_unit("adjusted_gross_income", period) - person = tax_unit.members - dependent = person("is_tax_unit_dependent", period) - earned_income = max_(0, person("earned", period)) - filing_status = tax_unit("filing_status", period) - non_dependent_income = ~dependent * earned_income - - # if tax unit is joint then pick the minimum of the non-dependent - # earned incomes, else pick the (only) max non-dependent income - tax_unit_min_income = where( - filing_status == filing_status.possible_values.JOINT, - tax_unit.sum(non_dependent_income) - - tax_unit.max(non_dependent_income), - tax_unit.max(non_dependent_income), - ) - - # earned_income = tax_unit("tax_unit_earned_income", period) childcare_expenses = tax_unit("tax_unit_childcare_expenses", period) # check for eligible children + person = tax_unit.members dependent = person("is_tax_unit_dependent", period) age = person("age", period) child = age < p.child_age_limit @@ -45,6 +30,7 @@ def formula(tax_unit, period, parameters): expense = min_(childcare_expenses, max_expense) # line 6 of worksheet + tax_unit_min_income = tax_unit("min_head_spouse_earned", period) credit = min_(expense, tax_unit_min_income) income_mult = p.income_mult.calc(agi) From 72efb0ca7ea3cab439c356cb094fb3185a1aa0fa Mon Sep 17 00:00:00 2001 From: mitchellpound Date: Thu, 10 Aug 2023 10:31:47 -0600 Subject: [PATCH 18/19] Added changelog entry --- changelog_entry.yaml | 2 +- .../income/credits/la_refundable_childcare.py | 18 ++---------------- 2 files changed, 3 insertions(+), 17 deletions(-) diff --git a/changelog_entry.yaml b/changelog_entry.yaml index 30a1a3815..fa4781306 100644 --- a/changelog_entry.yaml +++ b/changelog_entry.yaml @@ -1,4 +1,4 @@ - bump: minor changes: added: - - Added Minnesota state income tax logic with credits and refunds + - Added Louisiana state income tax logic with credits and refunds diff --git a/fiscalsim_us/variables/gov/states/la/tax/income/credits/la_refundable_childcare.py b/fiscalsim_us/variables/gov/states/la/tax/income/credits/la_refundable_childcare.py index 60bf47316..6d9624a25 100644 --- a/fiscalsim_us/variables/gov/states/la/tax/income/credits/la_refundable_childcare.py +++ b/fiscalsim_us/variables/gov/states/la/tax/income/credits/la_refundable_childcare.py @@ -16,25 +16,10 @@ class la_refundable_childcare(Variable): def formula(tax_unit, period, parameters): p = parameters(period).gov.states.la.tax.income.credits.refundable_p2.refundable_child_care agi = tax_unit("adjusted_gross_income", period) - person = tax_unit.members - dependent = person("is_tax_unit_dependent", period) - earned_income = max_(0, person("earned", period)) - filing_status = tax_unit("filing_status", period) - non_dependent_income = ~dependent * earned_income - - # if tax unit is joint then pick the minimum of the non-dependent - # earned incomes, else pick the (only) max non-dependent income - tax_unit_min_income = where( - filing_status == filing_status.possible_values.JOINT, - tax_unit.sum(non_dependent_income) - - tax_unit.max(non_dependent_income), - tax_unit.max(non_dependent_income), - ) - - # earned_income = tax_unit("tax_unit_earned_income", period) childcare_expenses = tax_unit("tax_unit_childcare_expenses", period) # check for eligible children + person = tax_unit.members dependent = person("is_tax_unit_dependent", period) age = person("age", period) child = age < p.child_age_limit @@ -45,6 +30,7 @@ def formula(tax_unit, period, parameters): expense = min_(childcare_expenses, max_expense) # line 6 of worksheet + tax_unit_min_income = tax_unit("min_head_spouse_earned", period) credit = min_(expense, tax_unit_min_income) income_mult = p.income_mult.calc(agi) From d9b5e8502fe11525a2ba95850b99e8cd0a3b17af Mon Sep 17 00:00:00 2001 From: mitchellpound Date: Wed, 20 Sep 2023 15:01:51 -0600 Subject: [PATCH 19/19] Black formatted files --- .../above_threshold_max.yaml | 2 +- .../nonrefundable_child_care/income_floor.yaml | 2 +- .../nonrefundable_child_care/income_mult.yaml | 2 +- .../nonrefundable_child_care/income_threshold.yaml | 2 +- .../gov/states/la/tax/income/la_exemptions.yaml | 2 +- .../income/credits/la_nonrefundable_childcare.py | 14 ++++++++++---- .../credits/la_nonrefundable_priority_3_credits.py | 2 +- .../income/credits/la_other_nonrefundable_p3.py | 2 +- .../tax/income/credits/la_refundable_childcare.py | 4 +++- .../gov/states/la/tax/income/la_exemptions.py | 3 ++- 10 files changed, 22 insertions(+), 13 deletions(-) diff --git a/fiscalsim_us/parameters/gov/states/la/tax/income/credits/nonrefundable_p3/nonrefundable_child_care/above_threshold_max.yaml b/fiscalsim_us/parameters/gov/states/la/tax/income/credits/nonrefundable_p3/nonrefundable_child_care/above_threshold_max.yaml index a360caf11..6d5aeb95f 100644 --- a/fiscalsim_us/parameters/gov/states/la/tax/income/credits/nonrefundable_p3/nonrefundable_child_care/above_threshold_max.yaml +++ b/fiscalsim_us/parameters/gov/states/la/tax/income/credits/nonrefundable_p3/nonrefundable_child_care/above_threshold_max.yaml @@ -13,4 +13,4 @@ metadata: - title: 2022 Louisiana Resident Income Tax Return, page 16-2A href: https://revenue.louisiana.gov/TaxForms/IT540WEB(2022)%20F%20D2.pdf - title: 2021 Louisiana Resident Income Tax Return, page 16-2A - href: https://revenue.louisiana.gov/TaxForms/IT540WEB(2021)%20F.pdf \ No newline at end of file + href: https://revenue.louisiana.gov/TaxForms/IT540WEB(2021)%20F.pdf diff --git a/fiscalsim_us/parameters/gov/states/la/tax/income/credits/nonrefundable_p3/nonrefundable_child_care/income_floor.yaml b/fiscalsim_us/parameters/gov/states/la/tax/income/credits/nonrefundable_p3/nonrefundable_child_care/income_floor.yaml index 40a0fd447..eca04f790 100644 --- a/fiscalsim_us/parameters/gov/states/la/tax/income/credits/nonrefundable_p3/nonrefundable_child_care/income_floor.yaml +++ b/fiscalsim_us/parameters/gov/states/la/tax/income/credits/nonrefundable_p3/nonrefundable_child_care/income_floor.yaml @@ -13,4 +13,4 @@ metadata: - title: 2022 Louisiana Resident Income Tax Return, page 14,16 href: https://revenue.louisiana.gov/TaxForms/IT540WEB(2022)%20F%20D2.pdf - title: 2021 Louisiana Resident Income Tax Return, page 14,16 - href: https://revenue.louisiana.gov/TaxForms/IT540WEB(2021)%20F.pdf \ No newline at end of file + href: https://revenue.louisiana.gov/TaxForms/IT540WEB(2021)%20F.pdf diff --git a/fiscalsim_us/parameters/gov/states/la/tax/income/credits/nonrefundable_p3/nonrefundable_child_care/income_mult.yaml b/fiscalsim_us/parameters/gov/states/la/tax/income/credits/nonrefundable_p3/nonrefundable_child_care/income_mult.yaml index 5f87e67f2..bff0df44f 100644 --- a/fiscalsim_us/parameters/gov/states/la/tax/income/credits/nonrefundable_p3/nonrefundable_child_care/income_mult.yaml +++ b/fiscalsim_us/parameters/gov/states/la/tax/income/credits/nonrefundable_p3/nonrefundable_child_care/income_mult.yaml @@ -26,4 +26,4 @@ metadata: - title: 2022 Louisiana Resident Income Tax Return href: https://revenue.louisiana.gov/TaxForms/IT540WEB(2022)%20F%20D2.pdf#page=16 - title: 2021 Louisiana Resident Income Tax Return - href: https://revenue.louisiana.gov/TaxForms/IT540WEB(2021)%20F.pdf#page=16 \ No newline at end of file + href: https://revenue.louisiana.gov/TaxForms/IT540WEB(2021)%20F.pdf#page=16 diff --git a/fiscalsim_us/parameters/gov/states/la/tax/income/credits/nonrefundable_p3/nonrefundable_child_care/income_threshold.yaml b/fiscalsim_us/parameters/gov/states/la/tax/income/credits/nonrefundable_p3/nonrefundable_child_care/income_threshold.yaml index 0896804f5..734d3936d 100644 --- a/fiscalsim_us/parameters/gov/states/la/tax/income/credits/nonrefundable_p3/nonrefundable_child_care/income_threshold.yaml +++ b/fiscalsim_us/parameters/gov/states/la/tax/income/credits/nonrefundable_p3/nonrefundable_child_care/income_threshold.yaml @@ -13,4 +13,4 @@ metadata: - title: 2022 Louisiana Resident Income Tax Return, page 16-2A href: https://revenue.louisiana.gov/TaxForms/IT540WEB(2022)%20F%20D2.pdf - title: 2021 Louisiana Resident Income Tax Return, page 16-2A - href: https://revenue.louisiana.gov/TaxForms/IT540WEB(2021)%20F.pdf \ No newline at end of file + href: https://revenue.louisiana.gov/TaxForms/IT540WEB(2021)%20F.pdf diff --git a/fiscalsim_us/tests/policy/baseline/gov/states/la/tax/income/la_exemptions.yaml b/fiscalsim_us/tests/policy/baseline/gov/states/la/tax/income/la_exemptions.yaml index 605cde711..6f51e6e4d 100644 --- a/fiscalsim_us/tests/policy/baseline/gov/states/la/tax/income/la_exemptions.yaml +++ b/fiscalsim_us/tests/policy/baseline/gov/states/la/tax/income/la_exemptions.yaml @@ -108,4 +108,4 @@ members: [person1, person2] state_code: LA output: - la_exemptions: 9_000 \ No newline at end of file + la_exemptions: 9_000 diff --git a/fiscalsim_us/variables/gov/states/la/tax/income/credits/la_nonrefundable_childcare.py b/fiscalsim_us/variables/gov/states/la/tax/income/credits/la_nonrefundable_childcare.py index dc451bc06..cf61dc8ca 100644 --- a/fiscalsim_us/variables/gov/states/la/tax/income/credits/la_nonrefundable_childcare.py +++ b/fiscalsim_us/variables/gov/states/la/tax/income/credits/la_nonrefundable_childcare.py @@ -14,17 +14,23 @@ class la_nonrefundable_childcare(Variable): ) def formula(tax_unit, period, parameters): - p = parameters(period).gov.states.la.tax.income.credits.nonrefundable_p3.nonrefundable_child_care + p = parameters( + period + ).gov.states.la.tax.income.credits.nonrefundable_p3.nonrefundable_child_care agi = tax_unit("adjusted_gross_income", period) fed_cdcc = tax_unit("cdcc", period) # for agi under income floor can use the refundable credit - nonrefundable = agi > p.income_floor + nonrefundable = agi > p.income_floor fed_cdcc = fed_cdcc * nonrefundable income_mult = p.income_mult.calc(agi) credit = fed_cdcc * income_mult - # for agi over the threshold the credit is the minimum of + # for agi over the threshold the credit is the minimum of # fed_cdcc * income_mult and the limit for above the threshold - return where(agi > p.income_threshold, min(credit, p.above_threshold_max), credit) + return where( + agi > p.income_threshold, + min(credit, p.above_threshold_max), + credit, + ) diff --git a/fiscalsim_us/variables/gov/states/la/tax/income/credits/la_nonrefundable_priority_3_credits.py b/fiscalsim_us/variables/gov/states/la/tax/income/credits/la_nonrefundable_priority_3_credits.py index 75a4f4d7f..39f2fc88f 100644 --- a/fiscalsim_us/variables/gov/states/la/tax/income/credits/la_nonrefundable_priority_3_credits.py +++ b/fiscalsim_us/variables/gov/states/la/tax/income/credits/la_nonrefundable_priority_3_credits.py @@ -12,4 +12,4 @@ class la_nonrefundable_priority_3_credits(Variable): "https://revenue.louisiana.gov/TaxForms/IT540WEB(2022)%20F%20D2.pdf", "https://revenue.louisiana.gov/TaxForms/IT540iWEB(2022)D1.pdf", ) - adds = "gov.states.la.tax.income.credits.nonrefundable_p3.sources" \ No newline at end of file + adds = "gov.states.la.tax.income.credits.nonrefundable_p3.sources" diff --git a/fiscalsim_us/variables/gov/states/la/tax/income/credits/la_other_nonrefundable_p3.py b/fiscalsim_us/variables/gov/states/la/tax/income/credits/la_other_nonrefundable_p3.py index 0eab749be..a1857fd04 100644 --- a/fiscalsim_us/variables/gov/states/la/tax/income/credits/la_other_nonrefundable_p3.py +++ b/fiscalsim_us/variables/gov/states/la/tax/income/credits/la_other_nonrefundable_p3.py @@ -53,4 +53,4 @@ class la_other_nonrefundable_p3(Variable): reference = ( "https://revenue.louisiana.gov/TaxForms/IT540WEB(2022)%20F%20D2.pdf", "https://revenue.louisiana.gov/TaxForms/IT540iWEB(2022)D1.pdf", - ) \ No newline at end of file + ) diff --git a/fiscalsim_us/variables/gov/states/la/tax/income/credits/la_refundable_childcare.py b/fiscalsim_us/variables/gov/states/la/tax/income/credits/la_refundable_childcare.py index 6d9624a25..8d8003392 100644 --- a/fiscalsim_us/variables/gov/states/la/tax/income/credits/la_refundable_childcare.py +++ b/fiscalsim_us/variables/gov/states/la/tax/income/credits/la_refundable_childcare.py @@ -14,7 +14,9 @@ class la_refundable_childcare(Variable): ) def formula(tax_unit, period, parameters): - p = parameters(period).gov.states.la.tax.income.credits.refundable_p2.refundable_child_care + p = parameters( + period + ).gov.states.la.tax.income.credits.refundable_p2.refundable_child_care agi = tax_unit("adjusted_gross_income", period) childcare_expenses = tax_unit("tax_unit_childcare_expenses", period) diff --git a/fiscalsim_us/variables/gov/states/la/tax/income/la_exemptions.py b/fiscalsim_us/variables/gov/states/la/tax/income/la_exemptions.py index 23cfc4767..5d3157870 100644 --- a/fiscalsim_us/variables/gov/states/la/tax/income/la_exemptions.py +++ b/fiscalsim_us/variables/gov/states/la/tax/income/la_exemptions.py @@ -15,7 +15,8 @@ def formula(tax_unit, period, parameters): filing_status = tax_unit("filing_status", period) statuses = filing_status.possible_values single_separate = (filing_status == statuses.SINGLE) | ( - filing_status == statuses.SEPARATE) + filing_status == statuses.SEPARATE + ) dependents = tax_unit("tax_unit_dependents", period) aged_blind = tax_unit("aged_blind_count", period)