Recipe 2: Estimating Behavioral Response to Reform

Recipe 2: Estimating Behavioral Response to Reform#

This is an advanced recipe that should be followed only after mastering the basic recipe. This recipe shows how to analyze the behavioral responses to a tax reform using the Tax-Calculator behresp module.

The assumed elasticities below specify a substitution elasticity of taxable income of 0.25 and leave the income elasticity (inc) and the capital-gains semi-elasticity (cg) at their default value of zero, so only the substitution response channel is active. Each elasticity is documented on the behavior parameters page.

import sys
if 'google.colab' in sys.modules:
    !pip install -q condacolab &> /dev/null # dev/null suppresses output
    import condacolab
    condacolab.install()
import taxcalc as tc

# use publicly-available CPS input file
recs = tc.Records.cps_constructor()

# specify baseline Calculator object representing current-law policy
pol = tc.Policy()
calc1 = tc.Calculator(policy=pol, records=recs)

CYR = 2020

# calculate aggregate current-law income tax liabilities for cyr
calc1.advance_to_year(CYR)
calc1.calc_all()
itax_rev1 = calc1.weighted_total('iitax')

# specify Calculator object for static analysis of reform policy
pol.implement_reform(tc.Policy.read_json_reform('github://PSLmodels:Tax-Calculator@master/docs/recipes/_static/reformA.json'))
calc2 = tc.Calculator(policy=pol, records=recs)

# calculate reform income tax liabilities for cyr under static assumptions
calc2.advance_to_year(CYR)
calc2.calc_all()
itax_rev2sa = calc2.weighted_total('iitax')

# specify assumed non-zero response-function substitution elasticity
# (the omitted 'esf', 'inc' and 'cg' parameters are assumed to be zero)
response_elasticities = {'sub': 0.25}

# specify Calculator object for analysis of reform with behavioral responses
# (the response function returns baseline and reform DataFrame objects and
#  leaves calc1 and calc2 unchanged; the discarded first DataFrame contains
#  the baseline results, which are the same as the calc1 results above)
calc2 = tc.Calculator(policy=pol, records=recs)
calc2.advance_to_year(CYR)
_, df2br = tc.response(calc1, calc2, response_elasticities)

# calculate reform income tax liabilities for CYR with behavioral response
# (weighted_total cannot be used here because the response function returns
#  a DataFrame rather than a Calculator object, so the weighting by the s006
#  filing-unit sampling weight must be done explicitly)
itax_rev2br = (df2br['iitax'] * df2br['s006']).sum()

# print total income tax revenue estimates for CYR
# (estimates in billons of dollars)
print('{}_CURRENT_LAW_P__itax_rev($B)= {:.3f}'.format(CYR, itax_rev1 * 1e-9))
print('{}_REFORM_STATIC__itax_rev($B)= {:.3f}'.format(CYR, itax_rev2sa * 1e-9))
print('{}_REFORM_DYNAMIC_itax_rev($B)= {:.3f}'.format(CYR, itax_rev2br * 1e-9))
2020_CURRENT_LAW_P__itax_rev($B)= 773.586
2020_REFORM_STATIC__itax_rev($B)= 777.761
2020_REFORM_DYNAMIC_itax_rev($B)= 765.480

Create multi-year diagnostic tables for

  1. baseline,

  2. reform excluding behavioral responses, and

  3. reform including behavioral responses

Each year in the loop below is analyzed independently: the response function is called once per year and no response computed in one year is carried over into another year. This means that retiming behavior, most notably the realization timing of capital gains, is not being modeled.

NUM_YEARS = 3  # number of diagnostic table years beginning with CYR
dtable1 = calc1.diagnostic_table(NUM_YEARS)
dtable2 = calc2.diagnostic_table(NUM_YEARS)
dvar_list3 = list()
year_list3 = list()
for year in range(CYR, CYR + NUM_YEARS):
    calc1.advance_to_year(year)
    calc2.advance_to_year(year)
    _, df2br = tc.response(calc1, calc2, response_elasticities)
    dvar_list3.append(df2br)
    year_list3.append(year)
dtable3 = tc.create_diagnostic_table(dvar_list3, year_list3)

Diagnostic table for baseline:

dtable1
2020 2021 2022
Returns (#m) 204.480 207.080 209.660
AGI ($b) 11572.618 13242.418 13524.301
Itemizers (#m) 27.730 31.470 31.360
Itemized Deduction ($b) 752.070 872.132 888.626
Standard Deduction Filers (#m) 176.760 175.600 178.300
Standard Deduction ($b) 3076.456 3093.014 3226.914
Personal Exemption ($b) 0.000 0.000 0.000
Taxable Income ($b) 8619.494 10113.673 10314.078
Regular Tax ($b) 1498.030 1776.937 1834.977
AMT Income ($b) 10952.965 12526.736 12790.771
AMT Liability ($b) 0.544 1.466 0.642
AMT Filers (#m) 0.070 0.190 0.080
Tax before Credits ($b) 1498.574 1778.403 1835.619
Refundable Credits ($b) 638.295 809.248 82.664
Nonrefundable Credits ($b) 99.269 0.005 107.426
Reform Surtaxes ($b) 0.000 0.000 0.000
Other Taxes ($b) 75.882 83.594 87.433
Ind Income Tax ($b) 773.586 984.073 1661.160
Payroll Taxes ($b) 1217.949 1321.377 1415.268
Combined Liability ($b) 1991.535 2305.451 3076.429
With Income Tax <= 0 (#m) 135.400 127.590 95.550
With Combined Tax <= 0 (#m) 97.110 96.390 65.170
UBI Benefits ($b) 0.000 0.000 0.000
Total Benefits, Consumption Value ($b) 3617.042 3992.973 4070.218
Total Benefits Cost ($b) 3617.042 3992.973 4070.218

Diagnostic table for reform, excluding behavioral responses:

dtable2
2020 2021 2022
Returns (#m) 204.480 207.080 209.660
AGI ($b) 11572.618 13242.418 13524.301
Itemizers (#m) 27.650 31.350 31.240
Itemized Deduction ($b) 749.589 868.770 885.538
Standard Deduction Filers (#m) 176.830 175.720 178.420
Standard Deduction ($b) 3077.794 3095.035 3228.878
Personal Exemption ($b) 375.177 384.158 406.780
Taxable Income ($b) 8371.709 9848.977 10037.841
Regular Tax ($b) 1499.855 1781.492 1841.599
AMT Income ($b) 10956.997 12531.565 12795.422
AMT Liability ($b) 0.551 1.494 0.642
AMT Filers (#m) 0.070 0.190 0.080
Tax before Credits ($b) 1500.406 1782.987 1842.241
Refundable Credits ($b) 641.613 809.248 86.370
Nonrefundable Credits ($b) 93.606 0.002 101.739
Reform Surtaxes ($b) 0.000 0.000 0.000
Other Taxes ($b) 75.882 83.594 87.433
Ind Income Tax ($b) 777.761 988.660 1669.763
Payroll Taxes ($b) 1217.949 1321.377 1415.268
Combined Liability ($b) 1995.711 2310.037 3085.031
With Income Tax <= 0 (#m) 137.560 129.830 98.410
With Combined Tax <= 0 (#m) 97.850 97.280 65.740
UBI Benefits ($b) 0.000 0.000 0.000
Total Benefits, Consumption Value ($b) 3617.042 3992.973 4070.218
Total Benefits Cost ($b) 3617.042 3992.973 4070.218

Diagnostic table for reform, including behavioral responses:

dtable3
2020 2021 2022
Returns (#m) 204.480 207.080 209.660
AGI ($b) 11545.734 13208.539 13488.608
Itemizers (#m) 27.620 31.320 31.230
Itemized Deduction ($b) 748.311 867.067 884.075
Standard Deduction Filers (#m) 176.860 175.750 178.440
Standard Deduction ($b) 3078.355 3095.710 3229.233
Personal Exemption ($b) 375.177 384.158 406.780
Taxable Income ($b) 8345.066 9815.640 10002.759
Regular Tax ($b) 1487.854 1766.985 1826.214
AMT Income ($b) 10930.714 12498.772 12760.598
AMT Liability ($b) 0.550 1.492 0.637
AMT Filers (#m) 0.070 0.190 0.080
Tax before Credits ($b) 1488.404 1768.477 1826.852
Refundable Credits ($b) 641.376 809.279 86.175
Nonrefundable Credits ($b) 93.823 0.002 101.972
Reform Surtaxes ($b) 0.000 0.000 0.000
Other Taxes ($b) 75.403 83.020 86.842
Ind Income Tax ($b) 765.480 973.749 1653.977
Payroll Taxes ($b) 1217.266 1320.307 1414.162
Combined Liability ($b) 1982.746 2294.056 3068.139
With Income Tax <= 0 (#m) 137.530 129.810 98.260
With Combined Tax <= 0 (#m) 97.830 97.260 65.600
UBI Benefits ($b) 0.000 0.000 0.000
Total Benefits, Consumption Value ($b) 3617.042 3992.973 4070.218
Total Benefits Cost ($b) 3617.042 3992.973 4070.218