taxcalc 4.2.0__tar.gz → 4.2.2__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {taxcalc-4.2.0 → taxcalc-4.2.2}/.github/workflows/build_and_test.yml +3 -3
- {taxcalc-4.2.0 → taxcalc-4.2.2}/.github/workflows/check_jupyterbook.yml +1 -1
- {taxcalc-4.2.0 → taxcalc-4.2.2}/PKG-INFO +3 -4
- {taxcalc-4.2.0 → taxcalc-4.2.2}/README.md +1 -1
- {taxcalc-4.2.0 → taxcalc-4.2.2}/conda.recipe/meta.yaml +6 -6
- {taxcalc-4.2.0 → taxcalc-4.2.2}/docs/about/releases.md +39 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/docs/index.md +1 -1
- {taxcalc-4.2.0 → taxcalc-4.2.2}/environment.yml +3 -3
- {taxcalc-4.2.0 → taxcalc-4.2.2}/extend_tcja.py +1 -1
- {taxcalc-4.2.0 → taxcalc-4.2.2}/ppp.py +1 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/setup.py +2 -3
- {taxcalc-4.2.0 → taxcalc-4.2.2}/taxcalc/__init__.py +1 -1
- {taxcalc-4.2.0 → taxcalc-4.2.2}/taxcalc/calcfunctions.py +81 -57
- {taxcalc-4.2.0 → taxcalc-4.2.2}/taxcalc/data.py +10 -5
- {taxcalc-4.2.0 → taxcalc-4.2.2}/taxcalc/policy_current_law.json +2012 -219
- {taxcalc-4.2.0 → taxcalc-4.2.2}/taxcalc/records_variables.json +6 -1
- {taxcalc-4.2.0 → taxcalc-4.2.2}/taxcalc/reforms/2017_law.json +1 -1
- {taxcalc-4.2.0 → taxcalc-4.2.2}/taxcalc/reforms/ARPA.json +4 -4
- {taxcalc-4.2.0 → taxcalc-4.2.2}/taxcalc/reforms/CARES.json +7 -4
- {taxcalc-4.2.0 → taxcalc-4.2.2}/taxcalc/reforms/TCJA.json +2 -10
- {taxcalc-4.2.0 → taxcalc-4.2.2}/taxcalc/reforms/archive/TCJA_Reconciliation.json +1 -1
- {taxcalc-4.2.0 → taxcalc-4.2.2}/taxcalc/reforms/archive/TCJA_Senate_111417.json +1 -1
- {taxcalc-4.2.0 → taxcalc-4.2.2}/taxcalc/reforms/archive/TCJA_Senate_120117.json +1 -1
- {taxcalc-4.2.0 → taxcalc-4.2.2}/taxcalc/reforms/ext.json +1 -1
- taxcalc-4.2.2/taxcalc/reforms/growfactors_ext.csv +65 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/taxcalc/reforms/rounding2022.json +14 -4
- {taxcalc-4.2.0 → taxcalc-4.2.2}/taxcalc/taxcalcio.py +4 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/taxcalc/tests/cmpi_cps_expect.txt +3 -3
- {taxcalc-4.2.0 → taxcalc-4.2.2}/taxcalc/tests/cmpi_puf_expect.txt +9 -9
- taxcalc-4.2.2/taxcalc/tests/cpscsv_agg_expect.csv +26 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/taxcalc/tests/puf_var_correl_coeffs_2016.csv +7 -7
- {taxcalc-4.2.0 → taxcalc-4.2.2}/taxcalc/tests/puf_var_wght_means_by_year.csv +7 -7
- taxcalc-4.2.2/taxcalc/tests/pufcsv_agg_expect.csv +26 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/taxcalc/tests/pufcsv_mtr_expect.txt +18 -18
- {taxcalc-4.2.0 → taxcalc-4.2.2}/taxcalc/tests/reforms_expect.csv +3 -3
- {taxcalc-4.2.0 → taxcalc-4.2.2}/taxcalc/tests/test_calcfunctions.py +35 -27
- {taxcalc-4.2.0 → taxcalc-4.2.2}/taxcalc/tests/test_reforms.py +2 -2
- {taxcalc-4.2.0 → taxcalc-4.2.2}/taxcalc/tests/test_taxcalcio.py +1 -1
- taxcalc-4.2.2/taxcalc/tmd_growfactors.csv +55 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/taxcalc/tmd_weights.csv.gz +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/taxcalc/validation/taxsim35/expected_differences/a21-taxdiffs-expect.csv +2 -2
- {taxcalc-4.2.0 → taxcalc-4.2.2}/taxcalc/validation/taxsim35/expected_differences/b18-taxdiffs-expect.csv +7 -7
- {taxcalc-4.2.0 → taxcalc-4.2.2}/taxcalc/validation/taxsim35/expected_differences/b19-taxdiffs-expect.csv +7 -7
- {taxcalc-4.2.0 → taxcalc-4.2.2}/taxcalc/validation/taxsim35/expected_differences/b20-taxdiffs-expect.csv +7 -7
- taxcalc-4.2.2/taxcalc/validation/taxsim35/expected_differences/b21-taxdiffs-expect.csv +25 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/taxcalc/validation/taxsim35/expected_differences/c18-taxdiffs-expect.csv +8 -8
- {taxcalc-4.2.0 → taxcalc-4.2.2}/taxcalc/validation/taxsim35/expected_differences/c19-taxdiffs-expect.csv +8 -8
- {taxcalc-4.2.0 → taxcalc-4.2.2}/taxcalc.egg-info/PKG-INFO +3 -4
- {taxcalc-4.2.0 → taxcalc-4.2.2}/taxcalc.egg-info/SOURCES.txt +1 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/taxcalc.egg-info/requires.txt +1 -1
- taxcalc-4.2.0/taxcalc/tests/cpscsv_agg_expect.csv +0 -26
- taxcalc-4.2.0/taxcalc/tests/pufcsv_agg_expect.csv +0 -26
- taxcalc-4.2.0/taxcalc/tmd_growfactors.csv +0 -55
- taxcalc-4.2.0/taxcalc/validation/taxsim35/expected_differences/b21-taxdiffs-expect.csv +0 -25
- {taxcalc-4.2.0 → taxcalc-4.2.2}/.coveragerc +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/.github/FUNDING.yml +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/.github/workflows/deploy_jupyterbook.yml +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/.github/workflows/deploy_parameters_docs.yml +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/.gitignore +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/LICENSE +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/MANIFEST.in +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/Makefile +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/PSL_catalog.json +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/codecov.yml +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/conda.recipe/bld.bat +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/conda.recipe/build.sh +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/csv_show.sh +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/csv_vars.sh +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/docs/PSL.svg +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/docs/_config.yml +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/docs/_static/atr.png +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/docs/_static/mtr.png +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/docs/_static/pch.png +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/docs/_toc.yml +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/docs/about/LICENSE.md +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/docs/about/history.md +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/docs/about/roadmap.md +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/docs/api/calcfunctions.rst +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/docs/api/calculator.rst +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/docs/api/consumption.rst +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/docs/api/data.rst +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/docs/api/decorators.rst +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/docs/api/growdiff.rst +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/docs/api/growfactors.rst +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/docs/api/parameters.rst +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/docs/api/policy.rst +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/docs/api/public_api.rst +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/docs/api/records.rst +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/docs/api/taxcalcio.rst +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/docs/api/utils.rst +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/docs/api/utilsprvt.rst +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/docs/contributing/RELEASING.md +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/docs/contributing/contributor_guide.md +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/docs/contributing/dependencies.md +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/docs/contributing/param_naming.md +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/docs/contributing/pr_workflow.md +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/docs/contributing/testing.md +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/docs/guide/README.md +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/docs/guide/assumption_params.md +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/docs/guide/cli.md +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/docs/guide/index.md +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/docs/guide/input_vars.md +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/docs/guide/make/make_io_vars.py +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/docs/guide/make/make_params.py +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/docs/guide/make/make_uguide.py +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/docs/guide/output_vars.md +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/docs/guide/policy_params.md +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/docs/guide/python_interface.md +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/docs/guide/templates/assumption_params_template.md +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/docs/guide/templates/input_vars_template.md +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/docs/guide/templates/output_vars_template.md +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/docs/guide/templates/policy_params_template.md +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/docs/recipes/README.md +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/docs/recipes/_static/reformA.json +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/docs/recipes/_static/reformB.json +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/docs/recipes/_static/reformC.json +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/docs/recipes/convert_all.sh +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/docs/recipes/index.md +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/docs/recipes/md_src/recipe00.md +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/docs/recipes/md_src/recipe01.md +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/docs/recipes/md_src/recipe02.md +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/docs/recipes/md_src/recipe03.md +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/docs/recipes/md_src/recipe04.md +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/docs/recipes/md_src/recipe04_pandas.md +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/docs/recipes/md_src/recipe05.md +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/docs/recipes/md_src/recipe06.md +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/docs/recipes/recipe00.ipynb +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/docs/recipes/recipe01.ipynb +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/docs/recipes/recipe02.ipynb +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/docs/recipes/recipe03.ipynb +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/docs/recipes/recipe04.ipynb +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/docs/recipes/recipe04_pandas.ipynb +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/docs/recipes/recipe05.ipynb +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/docs/recipes/recipe06.ipynb +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/docs/usage/data.md +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/docs/usage/overview.md +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/docs/usage/starting.md +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/docs/usage/tcja_after_2025.md +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/docs/use_cases.md +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/gitpr +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/gitpr.bat +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/gitsync +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/gitsync.bat +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/pytest.ini +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/setup.cfg +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/taxcalc/assumptions/ASSUMPTIONS.md +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/taxcalc/assumptions/README.md +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/taxcalc/assumptions/economic_assumptions_template.json +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/taxcalc/calculator.py +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/taxcalc/cli/__init__.py +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/taxcalc/cli/tc.py +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/taxcalc/conftest.py +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/taxcalc/consumption.json +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/taxcalc/consumption.py +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/taxcalc/cps.csv.gz +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/taxcalc/cps_weights.csv.gz +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/taxcalc/decorators.py +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/taxcalc/growdiff.json +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/taxcalc/growdiff.py +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/taxcalc/growfactors.csv +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/taxcalc/growfactors.py +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/taxcalc/parameters.py +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/taxcalc/policy.py +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/taxcalc/puf_ratios.csv +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/taxcalc/puf_weights.csv.gz +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/taxcalc/records.py +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/taxcalc/reforms/2017_law.out.csv +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/taxcalc/reforms/ARPA.out.csv +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/taxcalc/reforms/BrownKhanna.json +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/taxcalc/reforms/BrownKhanna.out.csv +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/taxcalc/reforms/CARES.out.csv +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/taxcalc/reforms/ConsolidatedAppropriationsAct2021.json +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/taxcalc/reforms/ConsolidatedAppropriationsAct2021.out.csv +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/taxcalc/reforms/Larson2019.json +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/taxcalc/reforms/Larson2019.out.csv +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/taxcalc/reforms/README.md +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/taxcalc/reforms/REFORMS.md +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/taxcalc/reforms/Renacci.json +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/taxcalc/reforms/Renacci.out.csv +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/taxcalc/reforms/SandersDeFazio.json +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/taxcalc/reforms/SandersDeFazio.out.csv +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/taxcalc/reforms/TCJA.md +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/taxcalc/reforms/TCJA.out.csv +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/taxcalc/reforms/Trump2016.json +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/taxcalc/reforms/Trump2016.out.csv +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/taxcalc/reforms/Trump2017.json +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/taxcalc/reforms/Trump2017.out.csv +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/taxcalc/reforms/archive/Clinton2016.json +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/taxcalc/reforms/archive/RyanBrady.json +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/taxcalc/reforms/archive/TCJA_House.json +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/taxcalc/reforms/archive/TCJA_House_Amended.json +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/taxcalc/reforms/archive/TCJA_Senate.json +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/taxcalc/reforms/cases.csv +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/taxcalc/reforms/clp.out.csv +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/taxcalc/reforms/ptaxes0.json +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/taxcalc/reforms/ptaxes0.out.csv +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/taxcalc/reforms/ptaxes1.json +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/taxcalc/reforms/ptaxes1.out.csv +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/taxcalc/reforms/ptaxes2.json +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/taxcalc/reforms/ptaxes2.out.csv +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/taxcalc/reforms/ptaxes3.json +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/taxcalc/reforms/ptaxes3.out.csv +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/taxcalc/reforms/rounding2022.out.csv +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/taxcalc/tests/benefits_expect.csv +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/taxcalc/tests/conftest.py +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/taxcalc/tests/reforms.json +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/taxcalc/tests/test_4package.py +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/taxcalc/tests/test_benefits.py +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/taxcalc/tests/test_calculator.py +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/taxcalc/tests/test_compare.py +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/taxcalc/tests/test_compatible_data.py +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/taxcalc/tests/test_consumption.py +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/taxcalc/tests/test_cpscsv.py +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/taxcalc/tests/test_data.py +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/taxcalc/tests/test_decorators.py +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/taxcalc/tests/test_growdiff.py +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/taxcalc/tests/test_growfactors.py +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/taxcalc/tests/test_parameters.py +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/taxcalc/tests/test_policy.py +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/taxcalc/tests/test_puf_var_stats.py +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/taxcalc/tests/test_pufcsv.py +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/taxcalc/tests/test_records.py +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/taxcalc/tests/test_responses.py +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/taxcalc/tests/test_tmdcsv.py +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/taxcalc/tests/test_utils.py +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/taxcalc/utils.py +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/taxcalc/utilsprvt.py +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/taxcalc/validation/CSV_INPUT_VARS.md +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/taxcalc/validation/CSV_OUTPUT_VARS.md +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/taxcalc/validation/README.md +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/taxcalc/validation/taxsim35/Differences_Explained.md +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/taxcalc/validation/taxsim35/README.md +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/taxcalc/validation/taxsim35/expected_differences/a17-taxdiffs-expect.csv +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/taxcalc/validation/taxsim35/expected_differences/a18-taxdiffs-expect.csv +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/taxcalc/validation/taxsim35/expected_differences/a19-taxdiffs-expect.csv +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/taxcalc/validation/taxsim35/expected_differences/a20-taxdiffs-expect.csv +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/taxcalc/validation/taxsim35/expected_differences/b17-taxdiffs-expect.csv +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/taxcalc/validation/taxsim35/expected_differences/c17-taxdiffs-expect.csv +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/taxcalc/validation/taxsim35/input_setup.py +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/taxcalc/validation/taxsim35/main_comparison.py +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/taxcalc/validation/taxsim35/prepare_taxcalc_input.py +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/taxcalc/validation/taxsim35/process_taxcalc_output.py +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/taxcalc/validation/taxsim35/taxsim_emulation.json +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/taxcalc/validation/taxsim35/taxsim_input.py +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/taxcalc/validation/taxsim35/tc_sims.py +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/taxcalc/validation/taxsim35/tests_35.py +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/taxcalc/validation/tests_35.sh +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/taxcalc.egg-info/dependency_links.txt +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/taxcalc.egg-info/entry_points.txt +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/taxcalc.egg-info/top_level.txt +0 -0
- {taxcalc-4.2.0 → taxcalc-4.2.2}/tctest-nojit.sh +0 -0
@@ -1,4 +1,4 @@
|
|
1
|
-
name: Build Package and Test Source Code [Python 3.
|
1
|
+
name: Build Package and Test Source Code [Python 3.10, 3.11, 3.12]
|
2
2
|
|
3
3
|
on: [push, pull_request]
|
4
4
|
|
@@ -8,7 +8,7 @@ jobs:
|
|
8
8
|
strategy:
|
9
9
|
matrix:
|
10
10
|
os: [ubuntu-latest, windows-latest]
|
11
|
-
python-version: [
|
11
|
+
python-version: ['3.10', '3.11', '3.12']
|
12
12
|
|
13
13
|
steps:
|
14
14
|
- name: Checkout
|
@@ -36,7 +36,7 @@ jobs:
|
|
36
36
|
run: |
|
37
37
|
pytest -m 'not requires_pufcsv and not requires_tmdcsv and not pre_release and not local' --cov=./ --cov-report=xml
|
38
38
|
- name: Upload coverage to Codecov
|
39
|
-
if: matrix.os == 'ubuntu-latest'
|
39
|
+
if: matrix.os == 'ubuntu-latest' && contains(github.repository, 'PSLmodels/Tax-Calculator')
|
40
40
|
uses: codecov/codecov-action@v4
|
41
41
|
with:
|
42
42
|
token: ${{ secrets.CODECOV_TOKEN }} # not required for public repos
|
@@ -1,6 +1,6 @@
|
|
1
1
|
Metadata-Version: 2.1
|
2
2
|
Name: taxcalc
|
3
|
-
Version: 4.2.
|
3
|
+
Version: 4.2.2
|
4
4
|
Summary: taxcalc
|
5
5
|
Home-page: https://github.com/PSLmodels/Tax-Calculator
|
6
6
|
Download-URL: https://github.com/PSLmodels/Tax-Calculator
|
@@ -12,7 +12,6 @@ Classifier: License :: CC0 1.0 Universal (CC0 1.0) Public Domain Dedication
|
|
12
12
|
Classifier: Operating System :: OS Independent
|
13
13
|
Classifier: Programming Language :: Python
|
14
14
|
Classifier: Programming Language :: Python :: 3
|
15
|
-
Classifier: Programming Language :: Python :: 3.9
|
16
15
|
Classifier: Programming Language :: Python :: 3.10
|
17
16
|
Classifier: Programming Language :: Python :: 3.11
|
18
17
|
Classifier: Programming Language :: Python :: 3.12
|
@@ -25,12 +24,12 @@ Requires-Dist: pandas
|
|
25
24
|
Requires-Dist: bokeh
|
26
25
|
Requires-Dist: numba
|
27
26
|
Requires-Dist: requests
|
28
|
-
Requires-Dist: paramtools
|
27
|
+
Requires-Dist: paramtools>=0.18.3
|
29
28
|
|
30
29
|
| | |
|
31
30
|
| --- | --- |
|
32
31
|
| Org | [](https://www.PSLmodels.org) [](https://github.com/PSLmodels/Tax-Calculator/blob/master/LICENSE) [](https://pslmodels.github.io/Tax-Calculator/) |
|
33
|
-
| Package | [](https://www.python.org/downloads/release/python-3108/) [](https://www.python.org/downloads/release/python-3118/) [](https://www.python.org/downloads/release/python-3121/) [](https://pypi.org/project/taxcalc/) [](https://pypi.org/project/taxcalc/) [](https://anaconda.org/conda-forge/taxcalc)|
|
34
33
|
| Testing |   [](https://codecov.io/gh/PSLmodels/Tax-Calculator) |
|
35
34
|
|
36
35
|
|
@@ -1,7 +1,7 @@
|
|
1
1
|
| | |
|
2
2
|
| --- | --- |
|
3
3
|
| Org | [](https://www.PSLmodels.org) [](https://github.com/PSLmodels/Tax-Calculator/blob/master/LICENSE) [](https://pslmodels.github.io/Tax-Calculator/) |
|
4
|
-
| Package | [](https://www.python.org/downloads/release/python-3108/) [](https://www.python.org/downloads/release/python-3118/) [](https://www.python.org/downloads/release/python-3121/) [](https://pypi.org/project/taxcalc/) [](https://pypi.org/project/taxcalc/) [](https://anaconda.org/conda-forge/taxcalc)|
|
5
5
|
| Testing |   [](https://codecov.io/gh/PSLmodels/Tax-Calculator) |
|
6
6
|
|
7
7
|
|
@@ -8,22 +8,22 @@ build:
|
|
8
8
|
|
9
9
|
requirements:
|
10
10
|
build:
|
11
|
-
- "python>=3.
|
12
|
-
- "numpy>=1.
|
11
|
+
- "python>=3.10, <3.13"
|
12
|
+
- "numpy>=1.26,<1.27"
|
13
13
|
- "pandas>=2.2"
|
14
14
|
- "bokeh>=2.4"
|
15
|
-
- "paramtools>=0.18.
|
15
|
+
- "paramtools>=0.18.3"
|
16
16
|
- numba
|
17
17
|
- curl
|
18
18
|
- openpyxl
|
19
19
|
- behresp
|
20
20
|
|
21
21
|
run:
|
22
|
-
- "python>=3.
|
23
|
-
- "numpy>=1.
|
22
|
+
- "python>=3.10, <3.13"
|
23
|
+
- "numpy>=1.26,<1.27"
|
24
24
|
- "pandas>=2.2"
|
25
25
|
- "bokeh>=2.4"
|
26
|
-
- "paramtools>=0.18.
|
26
|
+
- "paramtools>=0.18.3"
|
27
27
|
- numba
|
28
28
|
- curl
|
29
29
|
- openpyxl
|
@@ -3,6 +3,45 @@ Release history
|
|
3
3
|
Go [here](https://github.com/PSLmodels/Tax-Calculator/pulls?q=is%3Apr+is%3Aclosed)
|
4
4
|
for a complete commit history.
|
5
5
|
|
6
|
+
2024-09-14 Release 4.2.2
|
7
|
+
------------------------
|
8
|
+
(last merged pull request is
|
9
|
+
[#2801](https://github.com/PSLmodels/Tax-Calculator/pull/2801))
|
10
|
+
|
11
|
+
**This is a bug-fix release.**
|
12
|
+
|
13
|
+
**API Changes**
|
14
|
+
|
15
|
+
**New Features**
|
16
|
+
- Non-substantive, cosmetic changes to `policy_current_law.json` file [[#2791](https://github.com/PSLmodels/Tax-Calculator/pull/2791) by Martin Holmer]
|
17
|
+
-Update `tmd_growfactors.csv` and `tmd_weights.csv.gz` files file [[#2797](https://github.com/PSLmodels/Tax-Calculator/pull/2797) by Martin Holmer]
|
18
|
+
|
19
|
+
|
20
|
+
**Bug Fixes**
|
21
|
+
- Add missing pre-2022 values for indexed policy parameters [[#2789](https://github.com/PSLmodels/Tax-Calculator/pull/2789) by Martin Holmer]
|
22
|
+
- Fix education tax credit phase-out parameters [[#2790](https://github.com/PSLmodels/Tax-Calculator/pull/2790) by Martin Holmer]
|
23
|
+
- Several PRs with updates for dependency versions and other minor changes by Martin Holmer and Jason DeBacker
|
24
|
+
|
25
|
+
2024-07-30 Release 4.2.1
|
26
|
+
------------------------
|
27
|
+
(last merged pull request is
|
28
|
+
[#2786](https://github.com/PSLmodels/Tax-Calculator/pull/2786))
|
29
|
+
|
30
|
+
**This is a bug-fix release.**
|
31
|
+
|
32
|
+
**API Changes**
|
33
|
+
|
34
|
+
**New Features**
|
35
|
+
|
36
|
+
**Bug Fixes**
|
37
|
+
- Add custom `reforms/growfactors_ext.json` file to use in dynamic analysis of the `reforms/ext.json` extend-TCJA-beyond-2025 reform [[#2770](https://github.com/PSLmodels/Tax-Calculator/pull/2777) by Jason DeBacker]
|
38
|
+
- Fix CDCC phase-out calculations [[#2779](https://github.com/PSLmodels/Tax-Calculator/pull/2779) by Martin Holmer]
|
39
|
+
- Fix CARES charity deduction for nonitemizers [[#2781](https://github.com/PSLmodels/Tax-Calculator/pull/2781) by Martin Holmer]
|
40
|
+
- Fix four 2020 PT_rt? parameter values [[#2783](https://github.com/PSLmodels/Tax-Calculator/pull/2783) by Martin Holmer]
|
41
|
+
- Correct AMT taxable income calculation to handle QBID correctly [[#2784](https://github.com/PSLmodels/Tax-Calculator/pull/2784) by Martin Holmer]
|
42
|
+
- Fix qualified business income calculation [[#2785](https://github.com/PSLmodels/Tax-Calculator/pull/2785) by Martin Holmer]
|
43
|
+
- Add `ctc_nonrefundable` variable [[#2786](https://github.com/PSLmodels/Tax-Calculator/pull/2786) by Martin Holmer]
|
44
|
+
|
6
45
|
|
7
46
|
2024-07-21 Release 4.2.0
|
8
47
|
------------------------
|
@@ -57,7 +57,7 @@ The cross-model validation work with NBER's TAXSIM-27 model is described
|
|
57
57
|
|
58
58
|
## Latest release
|
59
59
|
|
60
|
-
{doc}`4.2.
|
60
|
+
{doc}`4.2.2 (2024-09-14) <about/releases>`
|
61
61
|
|
62
62
|
If you are already using Tax-Calculator, upgrade using the following command:
|
63
63
|
|
@@ -2,11 +2,10 @@ name: taxcalc-dev
|
|
2
2
|
channels:
|
3
3
|
- conda-forge
|
4
4
|
dependencies:
|
5
|
-
- "python>=3.
|
6
|
-
- "numpy>=1.
|
5
|
+
- "python>=3.10, <3.13"
|
6
|
+
- "numpy>=1.26,<1.27"
|
7
7
|
- "pandas>=2.2"
|
8
8
|
- "bokeh>=2.4"
|
9
|
-
- "paramtools>=0.18.2"
|
10
9
|
- numba
|
11
10
|
- curl
|
12
11
|
- pytest
|
@@ -19,3 +18,4 @@ dependencies:
|
|
19
18
|
- pip
|
20
19
|
- pip:
|
21
20
|
- jupyter-book
|
21
|
+
- "paramtools>=0.18.3"
|
@@ -58,7 +58,7 @@ TCJA_PARAMETERS = {
|
|
58
58
|
"STD": {"indexed": True, "category": 4},
|
59
59
|
# category 5 ...
|
60
60
|
"ID_AllTaxes_c": {"indexed": False, "category": 5},
|
61
|
-
"
|
61
|
+
"ID_Charity_crt_cash": {"indexed": False, "category": 5},
|
62
62
|
"ID_Casualty_hc": {"indexed": False, "category": 5},
|
63
63
|
"ID_Miscellaneous_hc": {"indexed": False, "category": 5},
|
64
64
|
"ID_ps": {"indexed": True, "category": 5},
|
@@ -3,7 +3,7 @@ from setuptools import setup
|
|
3
3
|
with open("README.md") as f:
|
4
4
|
longdesc = f.read()
|
5
5
|
|
6
|
-
version = "4.2.
|
6
|
+
version = "4.2.2"
|
7
7
|
|
8
8
|
config = {
|
9
9
|
"description": "Tax Calculator",
|
@@ -24,7 +24,7 @@ config = {
|
|
24
24
|
"bokeh",
|
25
25
|
"numba",
|
26
26
|
"requests",
|
27
|
-
"paramtools",
|
27
|
+
"paramtools>=0.18.3",
|
28
28
|
],
|
29
29
|
"classifiers": [
|
30
30
|
"Development Status :: 4 - Beta",
|
@@ -34,7 +34,6 @@ config = {
|
|
34
34
|
"Operating System :: OS Independent",
|
35
35
|
"Programming Language :: Python",
|
36
36
|
"Programming Language :: Python :: 3",
|
37
|
-
"Programming Language :: Python :: 3.9",
|
38
37
|
"Programming Language :: Python :: 3.10",
|
39
38
|
"Programming Language :: Python :: 3.11",
|
40
39
|
"Programming Language :: Python :: 3.12",
|
@@ -781,7 +781,7 @@ def ItemDedCap(e17500, e18400, e18500, e19200, e19800, e20100, e20400, g20500,
|
|
781
781
|
e19800: float
|
782
782
|
Itemizable charitable giving: cash/check contributions
|
783
783
|
e20100: float
|
784
|
-
Itemizable
|
784
|
+
Itemizable charitable giving: other than cash/check contributions
|
785
785
|
e20400: float
|
786
786
|
Itemizable gross (before 10% AGI disregard) casualty or theft loss
|
787
787
|
g20500: float
|
@@ -887,7 +887,7 @@ def ItemDed(e17500_capped, e18400_capped, e18500_capped, e19200_capped,
|
|
887
887
|
c17000, c18300, c19200, c19700, c20500, c20800,
|
888
888
|
ID_ps, ID_Medical_frt, ID_Medical_frt_add4aged, ID_Medical_hc,
|
889
889
|
ID_Casualty_frt, ID_Casualty_hc, ID_Miscellaneous_frt,
|
890
|
-
ID_Miscellaneous_hc,
|
890
|
+
ID_Miscellaneous_hc, ID_Charity_crt_cash, ID_Charity_crt_noncash,
|
891
891
|
ID_prt, ID_crt, ID_c, ID_StateLocalTax_hc, ID_Charity_frt,
|
892
892
|
ID_Charity_hc, ID_InterestPaid_hc, ID_RealEstate_hc,
|
893
893
|
ID_Medical_c, ID_StateLocalTax_c, ID_RealEstate_c,
|
@@ -957,8 +957,8 @@ def ItemDed(e17500_capped, e18400_capped, e18500_capped, e19200_capped,
|
|
957
957
|
Floor (as decimal fraction of AGI) for deductible miscellaneous expenses
|
958
958
|
ID_Miscellaneous_hc: float
|
959
959
|
Miscellaneous expense deduction haircut
|
960
|
-
|
961
|
-
Ceiling (as decimal fraction of AGI) for
|
960
|
+
ID_Charity_crt_cash: float
|
961
|
+
Ceiling (as decimal fraction of AGI) for cash charitable contribution deductions
|
962
962
|
ID_Charity_crt_noncash: float
|
963
963
|
Ceiling (as decimal fraction of AGI) for noncash charitable contribution deductions
|
964
964
|
ID_prt: float
|
@@ -1047,8 +1047,9 @@ def ItemDed(e17500_capped, e18400_capped, e18500_capped, e19200_capped,
|
|
1047
1047
|
c19200 = e19200_capped * (1. - ID_InterestPaid_hc)
|
1048
1048
|
c19200 = min(c19200, ID_InterestPaid_c[MARS - 1])
|
1049
1049
|
# Charity
|
1050
|
-
|
1051
|
-
|
1050
|
+
charity_ded_cash = min(ID_Charity_crt_cash * posagi, e19800_capped)
|
1051
|
+
charity_ded_noncash = min(ID_Charity_crt_noncash * posagi, e20100_capped)
|
1052
|
+
c19700 = charity_ded_cash + charity_ded_noncash
|
1052
1053
|
# charity floor is zero in present law
|
1053
1054
|
charity_floor = max(ID_Charity_frt * posagi, ID_Charity_f[MARS - 1])
|
1054
1055
|
c19700 = max(0., c19700 - charity_floor) * (1. - ID_Charity_hc)
|
@@ -1133,9 +1134,9 @@ def AdditionalMedicareTax(e00200, MARS,
|
|
1133
1134
|
|
1134
1135
|
@iterate_jit(nopython=True)
|
1135
1136
|
def StdDed(DSI, earned, STD, age_head, age_spouse, STD_Aged, STD_Dep,
|
1136
|
-
MARS, MIDR, blind_head, blind_spouse, standard,
|
1137
|
-
STD_allow_charity_ded_nonitemizers,
|
1138
|
-
STD_charity_ded_nonitemizers_max):
|
1137
|
+
MARS, MIDR, blind_head, blind_spouse, standard,
|
1138
|
+
STD_allow_charity_ded_nonitemizers, e19800, ID_Charity_crt_cash,
|
1139
|
+
c00100, STD_charity_ded_nonitemizers_max):
|
1139
1140
|
"""
|
1140
1141
|
Calculates standard deduction, including standard deduction for
|
1141
1142
|
dependents, aged and bind.
|
@@ -1166,12 +1167,16 @@ def StdDed(DSI, earned, STD, age_head, age_spouse, STD_Aged, STD_Dep,
|
|
1166
1167
|
1 if spouse is blind, 0 otherwise
|
1167
1168
|
standard: float
|
1168
1169
|
Standard deduction (zero for itemizers)
|
1169
|
-
c19700: float
|
1170
|
-
Schedule A: charity contributions deducted
|
1171
1170
|
STD_allow_charity_ded_nonitemizers: bool
|
1172
1171
|
Allow standard deduction filers to take the charitable contributions deduction
|
1172
|
+
e19800: float
|
1173
|
+
Schedule A: cash charitable contributions
|
1174
|
+
ID_Charity_crt_cash: float
|
1175
|
+
Fraction of AGI cap on cash charitable deductions
|
1176
|
+
c00100: float
|
1177
|
+
Federal AGI
|
1173
1178
|
STD_charity_ded_nonitemizers_max: float
|
1174
|
-
Ceiling amount (in dollars) for charitable deductions for
|
1179
|
+
Ceiling amount (in dollars) for charitable deductions for nonitemizers
|
1175
1180
|
|
1176
1181
|
Returns
|
1177
1182
|
-------
|
@@ -1199,13 +1204,15 @@ def StdDed(DSI, earned, STD, age_head, age_spouse, STD_Aged, STD_Dep,
|
|
1199
1204
|
standard = basic_stded + extra_stded
|
1200
1205
|
if MARS == 3 and MIDR == 1:
|
1201
1206
|
standard = 0.
|
1207
|
+
# calculate CARES cash charity deduction for nonitemizers
|
1202
1208
|
if STD_allow_charity_ded_nonitemizers:
|
1203
|
-
|
1209
|
+
capped_ded = min(e19800, ID_Charity_crt_cash * c00100)
|
1210
|
+
standard += min(capped_ded, STD_charity_ded_nonitemizers_max[MARS - 1])
|
1204
1211
|
return standard
|
1205
1212
|
|
1206
1213
|
|
1207
1214
|
@iterate_jit(nopython=True)
|
1208
|
-
def TaxInc(c00100, standard, c04470, c04600, MARS, e00900, e26270,
|
1215
|
+
def TaxInc(c00100, standard, c04470, c04600, MARS, e00900, c03260, e26270,
|
1209
1216
|
e02100, e27200, e00650, c01000, PT_SSTB_income,
|
1210
1217
|
PT_binc_w2_wages, PT_ubia_property, PT_qbid_rt,
|
1211
1218
|
PT_qbid_taxinc_thd, PT_qbid_taxinc_gap, PT_qbid_w2_wages_rt,
|
@@ -1229,6 +1236,8 @@ def TaxInc(c00100, standard, c04470, c04600, MARS, e00900, e26270,
|
|
1229
1236
|
Filing (marital) status. (1=single, 2=joint, 3=separate, 4=household-head, 5=widow(er))
|
1230
1237
|
e00900: float
|
1231
1238
|
Schedule C business net profit/loss for filing unit
|
1239
|
+
c03260: float
|
1240
|
+
Self-employment (SECA) tax above-the-line deduction
|
1232
1241
|
e26270: float
|
1233
1242
|
Schedule E: combined partnership and S-corporation net income/loss
|
1234
1243
|
e02100: float
|
@@ -1280,7 +1289,7 @@ def TaxInc(c00100, standard, c04470, c04600, MARS, e00900, e26270,
|
|
1280
1289
|
pre_qbid_taxinc = max(0., c00100 - max(c04470, standard) - c04600)
|
1281
1290
|
# calculate qualified business income deduction
|
1282
1291
|
qbided = 0.
|
1283
|
-
qbinc = max(0., e00900 + e26270 + e02100 + e27200)
|
1292
|
+
qbinc = max(0., e00900 - c03260 + e26270 + e02100 + e27200)
|
1284
1293
|
if qbinc > 0. and PT_qbid_rt > 0.:
|
1285
1294
|
qbid_before_limits = qbinc * PT_qbid_rt
|
1286
1295
|
lower_thd = PT_qbid_taxinc_thd[MARS - 1]
|
@@ -1899,7 +1908,7 @@ def AGIsurtax(c00100, MARS, AGI_surtax_trt, AGI_surtax_thd, taxbc, surtax):
|
|
1899
1908
|
def AMT(e07300, dwks13, standard, f6251, c00100, c18300, taxbc,
|
1900
1909
|
c04470, c17000, c20800, c21040, e24515, MARS, sep, dwks19,
|
1901
1910
|
dwks14, c05700, e62900, e00700, dwks10, age_head, age_spouse,
|
1902
|
-
earned, cmbtp,
|
1911
|
+
earned, cmbtp, qbided,
|
1903
1912
|
AMT_child_em_c_age, AMT_brk1,
|
1904
1913
|
AMT_em, AMT_prt, AMT_rt1, AMT_rt2,
|
1905
1914
|
AMT_child_em, AMT_em_ps, AMT_em_pe,
|
@@ -1936,7 +1945,7 @@ def AMT(e07300, dwks13, standard, f6251, c00100, c18300, taxbc,
|
|
1936
1945
|
c20800: float
|
1937
1946
|
Schedule A: net limited miscellaneous deductions deducted
|
1938
1947
|
c21040: float
|
1939
|
-
Itemized
|
1948
|
+
Itemized deductions that are phased out
|
1940
1949
|
e24515: float
|
1941
1950
|
Schedule D: Un-Recaptured Section 1250 Gain
|
1942
1951
|
MARS: int
|
@@ -1963,6 +1972,8 @@ def AMT(e07300, dwks13, standard, f6251, c00100, c18300, taxbc,
|
|
1963
1972
|
Earned income for filing unit
|
1964
1973
|
cmbtp: float
|
1965
1974
|
Estimate of income on (AMT) Form 6251 but not in AGI
|
1975
|
+
qbided: float
|
1976
|
+
Qualified business income deduction
|
1966
1977
|
AMT_child_em_c_age: float
|
1967
1978
|
Age ceiling for special AMT exemption
|
1968
1979
|
AMT_brk1: float
|
@@ -2014,11 +2025,11 @@ def AMT(e07300, dwks13, standard, f6251, c00100, c18300, taxbc,
|
|
2014
2025
|
# pylint: disable=too-many-statements,too-many-branches
|
2015
2026
|
# Form 6251, Part I
|
2016
2027
|
if standard == 0.0:
|
2017
|
-
c62100 = (c00100 - e00700 - c04470 +
|
2028
|
+
c62100 = (c00100 - e00700 - qbided - c04470 +
|
2018
2029
|
max(0., min(c17000, 0.025 * c00100)) +
|
2019
2030
|
c18300 + c20800 - c21040)
|
2020
2031
|
if standard > 0.0:
|
2021
|
-
c62100 = c00100 - e00700
|
2032
|
+
c62100 = c00100 - e00700 - qbided
|
2022
2033
|
c62100 += cmbtp # add income not in AGI but considered income for AMT
|
2023
2034
|
if MARS == 3:
|
2024
2035
|
amtsepadd = max(0.,
|
@@ -2136,7 +2147,8 @@ def NetInvIncTax(e00300, e00600, e02000, e26270, c01000,
|
|
2136
2147
|
@iterate_jit(nopython=True)
|
2137
2148
|
def F2441(MARS, earned_p, earned_s, f2441, CDCC_c, e32800,
|
2138
2149
|
exact, c00100, CDCC_ps, CDCC_ps2, CDCC_crt, CDCC_frt,
|
2139
|
-
|
2150
|
+
CDCC_po_step_size, CDCC_po_rate_per_step, CDCC_refundable,
|
2151
|
+
c05800, e07300, c07180, CDCC_refund):
|
2140
2152
|
"""
|
2141
2153
|
Calculates Form 2441 child and dependent care expense credit, c07180.
|
2142
2154
|
|
@@ -2166,16 +2178,18 @@ def F2441(MARS, earned_p, earned_s, f2441, CDCC_c, e32800,
|
|
2166
2178
|
Child/dependent care credit phaseout rate ceiling
|
2167
2179
|
CDCC_frt: float
|
2168
2180
|
Child/dependent care credit phaseout rate floor
|
2169
|
-
|
2170
|
-
Child/dependent care credit phaseout
|
2181
|
+
CDCC_po_step_size: float
|
2182
|
+
Child/dependent care credit phaseout AGI step size
|
2183
|
+
CDCC_po_rate_per_step: float
|
2184
|
+
Child/dependent care credit phaseout rate per step size
|
2185
|
+
CDCC_refund: bool
|
2186
|
+
Indicator for whether CDCC is refundable
|
2171
2187
|
c05800: float
|
2172
2188
|
Total (regular + AMT) income tax liability before credits
|
2173
2189
|
e07300: float
|
2174
2190
|
Foreign tax credit from Form 1116
|
2175
2191
|
c07180: float
|
2176
2192
|
Credit for child and dependent care expenses from Form 2441
|
2177
|
-
CDCC_refund: bool
|
2178
|
-
Indicator for whether CDCC is refundable
|
2179
2193
|
|
2180
2194
|
Returns
|
2181
2195
|
-------
|
@@ -2192,22 +2206,22 @@ def F2441(MARS, earned_p, earned_s, f2441, CDCC_c, e32800,
|
|
2192
2206
|
else:
|
2193
2207
|
c32890 = earned_p
|
2194
2208
|
c33000 = max(0., min(c32800, min(c32880, c32890)))
|
2195
|
-
# credit is limited
|
2209
|
+
# credit rate is limited at high AGI
|
2210
|
+
# ... first phase-down from CDCC_crt to CDCC_frt
|
2211
|
+
steps_fractional = max(0., c00100 - CDCC_ps) / CDCC_po_step_size
|
2196
2212
|
if exact == 1: # exact calculation as on tax forms
|
2197
|
-
|
2198
|
-
tratio1 = math.ceil(max(((c00100 - CDCC_ps) * CDCC_prt), 0.))
|
2199
|
-
crate = max(CDCC_frt, CDCC_crt - min(CDCC_crt - CDCC_frt, tratio1))
|
2200
|
-
# second phase-down from 20 percent to zero
|
2201
|
-
if c00100 > CDCC_ps2:
|
2202
|
-
tratio2 = math.ceil(max(((c00100 - CDCC_ps2) * CDCC_prt), 0.))
|
2203
|
-
crate = max(0., CDCC_frt - min(CDCC_frt, tratio2))
|
2213
|
+
steps = math.ceil(steps_fractional)
|
2204
2214
|
else:
|
2205
|
-
|
2206
|
-
|
2207
|
-
|
2208
|
-
|
2209
|
-
|
2210
|
-
|
2215
|
+
steps = steps_fractional
|
2216
|
+
crate = max(CDCC_frt, CDCC_crt - steps * CDCC_po_rate_per_step)
|
2217
|
+
# ... second phase-down from CDCC_frt to zero
|
2218
|
+
if c00100 > CDCC_ps2:
|
2219
|
+
steps_fractional = (c00100 - CDCC_ps2) / CDCC_po_step_size
|
2220
|
+
if exact == 1: # exact calculation as on tax forms
|
2221
|
+
steps = math.ceil(steps_fractional)
|
2222
|
+
else:
|
2223
|
+
steps = steps_fractional
|
2224
|
+
crate = max(0., CDCC_frt - steps * CDCC_po_rate_per_step)
|
2211
2225
|
c33200 = c33000 * crate
|
2212
2226
|
# credit is limited by tax liability if not refundable
|
2213
2227
|
if CDCC_refundable:
|
@@ -2441,7 +2455,7 @@ def ChildDepTaxCredit(age_head, age_spouse, nu18, n24, MARS, c00100, XTOT, num,
|
|
2441
2455
|
c07200,
|
2442
2456
|
CTC_c, CTC_ps, CTC_prt, exact, ODC_c,
|
2443
2457
|
CTC_c_under6_bonus, nu06,
|
2444
|
-
|
2458
|
+
CTC_is_refundable, CTC_include17,
|
2445
2459
|
c07220, odc, codtc_limited):
|
2446
2460
|
"""
|
2447
2461
|
Computes amounts on "Child Tax Credit and Credit for Other Dependents
|
@@ -2540,7 +2554,7 @@ def ChildDepTaxCredit(age_head, age_spouse, nu18, n24, MARS, c00100, XTOT, num,
|
|
2540
2554
|
line13 = line11 - line12
|
2541
2555
|
line14 = 0.
|
2542
2556
|
line15 = max(0., line13 - line14)
|
2543
|
-
if
|
2557
|
+
if CTC_is_refundable:
|
2544
2558
|
c07220 = line10 * line1 / line3
|
2545
2559
|
odc = max(0., line10 - c07220)
|
2546
2560
|
codtc_limited = max(0., line10 - c07220 - odc)
|
@@ -2795,7 +2809,7 @@ def SchR(age_head, age_spouse, MARS, c00100,
|
|
2795
2809
|
|
2796
2810
|
|
2797
2811
|
@iterate_jit(nopython=True)
|
2798
|
-
def EducationTaxCredit(exact, e87530, MARS, c00100,
|
2812
|
+
def EducationTaxCredit(exact, e87530, MARS, c00100, c05800,
|
2799
2813
|
e07300, c07180, c07200, c87668,
|
2800
2814
|
LLC_Expense_c, ETC_pe_Single, ETC_pe_Married,
|
2801
2815
|
CR_Education_hc,
|
@@ -2814,8 +2828,6 @@ def EducationTaxCredit(exact, e87530, MARS, c00100, num, c05800,
|
|
2814
2828
|
Filing (marital) status. (1=single, 2=joint, 3=separate, 4=household-head, 5=widow(er))
|
2815
2829
|
c00100: float
|
2816
2830
|
Adjusted Gross Income (AGI)
|
2817
|
-
num: int
|
2818
|
-
2 when MARS is 2 (married filing jointly), otherwise 1
|
2819
2831
|
c05800: float
|
2820
2832
|
Total (regular + AMT) income tax liability before credits
|
2821
2833
|
e07300: float
|
@@ -2846,14 +2858,19 @@ def EducationTaxCredit(exact, e87530, MARS, c00100, num, c05800,
|
|
2846
2858
|
-----
|
2847
2859
|
Tax Law Parameters that are not parameterized:
|
2848
2860
|
0.2: Lifetime Learning Credit ratio against expense
|
2861
|
+
10000.0: AGI range bewteen ETC_pe_Single and single phase-out start;
|
2862
|
+
twice this amount for ETC_pe_Married
|
2849
2863
|
"""
|
2850
2864
|
c87560 = 0.2 * min(e87530, LLC_Expense_c)
|
2865
|
+
# on the following credit phase-out law see:
|
2866
|
+
# https://www.law.cornell.edu/uscode/text/26/25A#d_1
|
2851
2867
|
if MARS == 2:
|
2852
2868
|
c87570 = ETC_pe_Married * 1000.
|
2869
|
+
c87600 = 20000.
|
2853
2870
|
else:
|
2854
2871
|
c87570 = ETC_pe_Single * 1000.
|
2872
|
+
c87600 = 10000.
|
2855
2873
|
c87590 = max(0., c87570 - c00100)
|
2856
|
-
c87600 = 10000. * num
|
2857
2874
|
if exact == 1: # exact calculation as on tax forms
|
2858
2875
|
c87610 = min(1., round(c87590 / c87600, 3))
|
2859
2876
|
else:
|
@@ -2910,7 +2927,7 @@ def CharityCredit(e19800, e20100, c00100, CR_Charity_rt, CR_Charity_f,
|
|
2910
2927
|
def NonrefundableCredits(c05800, e07240, e07260, e07300, e07400,
|
2911
2928
|
e07600, p08000, odc,
|
2912
2929
|
personal_nonrefundable_credit,
|
2913
|
-
|
2930
|
+
CTC_is_refundable,
|
2914
2931
|
CR_RetirementSavings_hc, CR_ForeignTax_hc,
|
2915
2932
|
CR_ResidentialEnergy_hc, CR_GeneralBusiness_hc,
|
2916
2933
|
CR_MinimumTax_hc, CR_OtherCredits_hc, charity_credit,
|
@@ -2939,7 +2956,7 @@ def NonrefundableCredits(c05800, e07240, e07260, e07300, e07400,
|
|
2939
2956
|
Other Dependent Credit
|
2940
2957
|
personal_nonrefundable_credit: float
|
2941
2958
|
Personal nonrefundable credit
|
2942
|
-
|
2959
|
+
CTC_is_refundable: bool
|
2943
2960
|
Whether the child tax credit is fully refundable
|
2944
2961
|
CR_RetirementSavings_hc: float
|
2945
2962
|
Credit for retirement savings haircut
|
@@ -3019,7 +3036,7 @@ def NonrefundableCredits(c05800, e07240, e07260, e07300, e07400,
|
|
3019
3036
|
c07240 = min(e07240 * (1. - CR_RetirementSavings_hc), avail)
|
3020
3037
|
avail = avail - c07240
|
3021
3038
|
# Child tax credit
|
3022
|
-
if not
|
3039
|
+
if not CTC_is_refundable:
|
3023
3040
|
c07220 = min(c07220, avail)
|
3024
3041
|
avail = avail - c07220
|
3025
3042
|
# Other dependent credit
|
@@ -3053,7 +3070,8 @@ def NonrefundableCredits(c05800, e07240, e07260, e07300, e07400,
|
|
3053
3070
|
@iterate_jit(nopython=True)
|
3054
3071
|
def AdditionalCTC(codtc_limited, ACTC_c, n24, earned, ACTC_Income_thd,
|
3055
3072
|
ACTC_rt, nu06, ACTC_rt_bonus_under6family, ACTC_ChildNum,
|
3056
|
-
|
3073
|
+
CTC_is_refundable, CTC_include17,
|
3074
|
+
age_head, age_spouse, MARS, nu18,
|
3057
3075
|
ptax_was, c03260, e09800, c59660, e11200,
|
3058
3076
|
c11070):
|
3059
3077
|
"""
|
@@ -3101,7 +3119,7 @@ def AdditionalCTC(codtc_limited, ACTC_c, n24, earned, ACTC_Income_thd,
|
|
3101
3119
|
# Part I
|
3102
3120
|
line3 = codtc_limited
|
3103
3121
|
|
3104
|
-
if
|
3122
|
+
if CTC_is_refundable:
|
3105
3123
|
line4 = 0.
|
3106
3124
|
else:
|
3107
3125
|
if CTC_include17:
|
@@ -3142,7 +3160,8 @@ def AdditionalCTC(codtc_limited, ACTC_c, n24, earned, ACTC_Income_thd,
|
|
3142
3160
|
def C1040(c05800, c07180, c07200, c07220, c07230, c07240, c07260, c07300,
|
3143
3161
|
c07400, c07600, c08000, e09700, e09800, e09900, niit, othertaxes,
|
3144
3162
|
c07100, c09200, odc, charity_credit,
|
3145
|
-
personal_nonrefundable_credit,
|
3163
|
+
personal_nonrefundable_credit,
|
3164
|
+
CTC_is_refundable, ODC_is_refundable):
|
3146
3165
|
"""
|
3147
3166
|
Computes total used nonrefundable credits, c07100, othertaxes, and
|
3148
3167
|
income tax before refundable credits, c09200.
|
@@ -3203,8 +3222,9 @@ def C1040(c05800, c07180, c07200, c07220, c07230, c07240, c07260, c07300,
|
|
3203
3222
|
"""
|
3204
3223
|
# total used nonrefundable credits (as computed in NonrefundableCredits)
|
3205
3224
|
c07100 = (c07180 + c07200 + c07600 + c07300 + c07400 +
|
3206
|
-
c07220 * (1. -
|
3207
|
-
c07230 + c07240 + c07260 +
|
3225
|
+
c07220 * (1. - CTC_is_refundable) + c08000 +
|
3226
|
+
c07230 + c07240 + c07260 +
|
3227
|
+
odc * (1. - ODC_is_refundable) + charity_credit +
|
3208
3228
|
personal_nonrefundable_credit)
|
3209
3229
|
# tax after credits (2016 Form 1040, line 56)
|
3210
3230
|
tax_net_nonrefundable_credits = max(0., c05800 - c07100)
|
@@ -3305,8 +3325,8 @@ def CTC_new(CTC_new_c, CTC_new_rt, CTC_new_c_under6_bonus,
|
|
3305
3325
|
@iterate_jit(nopython=True)
|
3306
3326
|
def IITAX(c59660, c11070, c10960, personal_refundable_credit, ctc_new, rptc,
|
3307
3327
|
c09200, payrolltax, CDCC_refund, recovery_rebate_credit,
|
3308
|
-
eitc, c07220, odc,
|
3309
|
-
ctc_total, ctc_refundable, iitax, combined):
|
3328
|
+
eitc, c07220, odc, CTC_is_refundable, ODC_is_refundable, refund,
|
3329
|
+
ctc_total, ctc_refundable, ctc_nonrefundable, iitax, combined):
|
3310
3330
|
"""
|
3311
3331
|
Computes final taxes.
|
3312
3332
|
|
@@ -3352,17 +3372,19 @@ def IITAX(c59660, c11070, c10960, personal_refundable_credit, ctc_new, rptc,
|
|
3352
3372
|
Total CTC amount (c07220 + c11070 + odc + ctc_new)
|
3353
3373
|
ctc_refundable: float
|
3354
3374
|
Portion of total CTC amount that is refundable
|
3375
|
+
ctc_nonrefundable: float
|
3376
|
+
Portion of total CTC amount that is nonrefundable
|
3355
3377
|
iitax: float
|
3356
3378
|
Total federal individual income tax liability
|
3357
3379
|
combined: float
|
3358
3380
|
Sum of iitax and payrolltax and lumpsum_tax
|
3359
3381
|
"""
|
3360
3382
|
eitc = c59660
|
3361
|
-
if
|
3383
|
+
if CTC_is_refundable:
|
3362
3384
|
ctc_refund = c07220
|
3363
3385
|
else:
|
3364
3386
|
ctc_refund = 0.
|
3365
|
-
if
|
3387
|
+
if ODC_is_refundable:
|
3366
3388
|
odc_refund = odc
|
3367
3389
|
else:
|
3368
3390
|
odc_refund = 0.
|
@@ -3371,9 +3393,11 @@ def IITAX(c59660, c11070, c10960, personal_refundable_credit, ctc_new, rptc,
|
|
3371
3393
|
odc_refund)
|
3372
3394
|
ctc_total = c07220 + c11070 + odc + ctc_new
|
3373
3395
|
ctc_refundable = ctc_refund + c11070 + odc_refund + ctc_new
|
3396
|
+
ctc_nonrefundable = max(0., ctc_total - ctc_refundable)
|
3374
3397
|
iitax = c09200 - refund
|
3375
3398
|
combined = iitax + payrolltax
|
3376
|
-
return (eitc, refund, ctc_total, ctc_refundable,
|
3399
|
+
return (eitc, refund, ctc_total, ctc_refundable, ctc_nonrefundable,
|
3400
|
+
iitax, combined)
|
3377
3401
|
|
3378
3402
|
|
3379
3403
|
@JIT(nopython=True)
|
@@ -102,7 +102,7 @@ class Data():
|
|
102
102
|
# ... weights must be same size as data
|
103
103
|
if self.array_length > len(self.WT.index):
|
104
104
|
raise ValueError("Data has more records than weights.")
|
105
|
-
|
105
|
+
if self.array_length < len(self.WT.index):
|
106
106
|
# scale-up sub-sample weights by year-specific factor
|
107
107
|
sum_full_weights = self.WT.sum()
|
108
108
|
self.WT = self.WT.iloc[self.__index]
|
@@ -110,9 +110,11 @@ class Data():
|
|
110
110
|
factor = sum_full_weights / sum_sub_weights
|
111
111
|
self.WT *= factor
|
112
112
|
# ... construct sample weights for current_year
|
113
|
-
wt_colname = 'WT{
|
114
|
-
|
115
|
-
|
113
|
+
wt_colname = f'WT{self.current_year}'
|
114
|
+
assert wt_colname in self.WT.columns, (
|
115
|
+
f'no weights for start year {self.current_year}'
|
116
|
+
)
|
117
|
+
self.s006 = self.WT[wt_colname] * 0.01
|
116
118
|
|
117
119
|
@property
|
118
120
|
def data_year(self):
|
@@ -146,7 +148,10 @@ class Data():
|
|
146
148
|
# ... apply variable extrapolation growth factors
|
147
149
|
self._extrapolate(self.__current_year)
|
148
150
|
# ... specify current-year sample weights
|
149
|
-
wt_colname = 'WT{
|
151
|
+
wt_colname = f'WT{self.__current_year}'
|
152
|
+
assert wt_colname in self.WT.columns, (
|
153
|
+
f'no weights for new year {self.current_year}'
|
154
|
+
)
|
150
155
|
self.s006 = self.WT[wt_colname] * 0.01
|
151
156
|
|
152
157
|
# ----- begin private methods of Data class -----
|