Skip to content

Commit

Permalink
Merge pull request #1819 from codykallen/modify_pt_exclusion
Browse files Browse the repository at this point in the history
Modify pass-through exclusion calculation
  • Loading branch information
martinholmer authored Jan 11, 2018
2 parents fac067c + 27f4973 commit 85d9d81
Show file tree
Hide file tree
Showing 7 changed files with 125 additions and 26 deletions.
2 changes: 1 addition & 1 deletion docs/index.html

Large diffs are not rendered by default.

88 changes: 85 additions & 3 deletions taxcalc/current_law_policy.json
Original file line number Diff line number Diff line change
Expand Up @@ -619,6 +619,36 @@
"out_of_range_action": "stop"
},

"_ALD_BusinessLosses_c": {
"long_name": "Maximum amount of business losses deductible",
"description": "Business losses in excess of this amount may not be deducted from AGI.",
"section_1": "Above The Line Deductions",
"section_2": "Misc. Exclusions",
"irs_ref": "",
"notes": "",
"row_var": "FLPDYR",
"row_label": ["2013",
"2014",
"2015",
"2016",
"2017"],
"start_year": 2013,
"cpi_inflated": true,
"col_var": "MARS",
"col_label": ["single", "joint", "separate", "headhousehold", "widow"],
"boolean_value": false,
"integer_value": false,
"value": [[9e99, 9e99, 9e99, 9e99, 9e99],
[9e99, 9e99, 9e99, 9e99, 9e99],
[9e99, 9e99, 9e99, 9e99, 9e99],
[9e99, 9e99, 9e99, 9e99, 9e99],
[9e99, 9e99, 9e99, 9e99, 9e99]],
"range": {"min": 0.0, "max": 9e99},
"out_of_range_minmsg": "",
"out_of_range_maxmsg": "",
"out_of_range_action": "stop"
},

"_II_em": {
"long_name": "Personal and dependent exemption amount",
"description": "Subtracted from AGI in the calculation of taxable income, per taxpayer and dependent.",
Expand Down Expand Up @@ -3189,7 +3219,7 @@
"out_of_range_action": "stop"
},

"_PT_exclusion_rt": {
"_PT_excl_rt": {
"long_name": "Pass-through income exclusion rate",
"description": "Fraction of qualified business income excluded from taxable income.",
"section_1": "Personal Income",
Expand All @@ -3211,8 +3241,8 @@
"out_of_range_action": "stop"
},

"_PT_exclusion_wage_limit": {
"long_name": "Limit on pass-through income exclusion",
"_PT_excl_wagelim_rt": {
"long_name": "Wage limit rate on pass-through income exclusion",
"description": "If taxpayer has partnership/ S corporation income, the amount of business income excluded from taxable income may not exceed this fraction of wages.",
"section_1": "Personal Income",
"section_2": "Pass-Through",
Expand All @@ -3233,6 +3263,58 @@
"out_of_range_action": "stop"
},

"_PT_excl_wagelim_thd": {
"long_name": "Phase-in threshold of wage limit on pass-through income exclusion",
"description": "If taxpayer has partnership/ S corporation income, the amount of business income excluded from taxable income is limited by wages if taxable income exceeds this threshold.",
"section_1": "Personal Income",
"section_2": "Pass-Through",
"irs_ref": "",
"notes": "",
"row_var": "FLPDYR",
"row_label": ["2013",
"2014",
"2015",
"2016",
"2017"],
"start_year": 2013,
"cpi_inflated": true,
"col_var": "MARS",
"col_label": ["single", "joint", "separate", "headhousehold", "widow"],
"boolean_value": false,
"integer_value": false,
"value": [[0.0, 0.0, 0.0, 0.0, 0.0],
[0.0, 0.0, 0.0, 0.0, 0.0],
[0.0, 0.0, 0.0, 0.0, 0.0],
[0.0, 0.0, 0.0, 0.0, 0.0],
[0.0, 0.0, 0.0, 0.0, 0.0]],
"range": {"min": 0.0, "max": 9e99},
"out_of_range_minmsg": "",
"out_of_range_maxmsg": "",
"out_of_range_action": "stop"
},

"_PT_excl_wagelim_prt": {
"long_name": "Phase-in rate of wage limit on pass-through income exclusion",
"description": "If taxpayer has partnership/ S corporation income, the wage limitation on the amount of business income excluded from taxable income is phased in at this rate.",
"section_1": "Personal Income",
"section_2": "Pass-Through",
"irs_ref": "",
"notes": "",
"row_var": "FLPDYR",
"row_label": ["2013"],
"start_year": 2013,
"cpi_inflated": false,
"col_var": "MARS",
"col_label": ["single", "joint", "separate", "headhousehold", "widow"],
"boolean_value": false,
"integer_value": false,
"value": [[1.0, 1.0, 1.0, 1.0, 1.0]],
"range": {"min": 0.0, "max": 1.0},
"out_of_range_minmsg": "",
"out_of_range_maxmsg": "",
"out_of_range_action": "stop"
},

"_AMT_em": {
"long_name": "AMT exemption amount",
"description": "The amount of AMT taxable income exempted from AMT.",
Expand Down
32 changes: 20 additions & 12 deletions taxcalc/functions.py
Original file line number Diff line number Diff line change
Expand Up @@ -222,6 +222,7 @@ def CapGains(p23250, p22250, sep, ALD_StudentLoan_hc,
ALD_InvInc_ec_rt, invinc_ec_base, ALD_InvInc_ec_base_RyanBrady,
e00200, e00300, e00600, e00650, e00700, e00800,
CG_nodiff, CG_ec, CG_reinvest_ec_rt,
ALD_BusinessLosses_c, MARS, c02900_in_ei,
e00900, e01100, e01200, e01400, e01700, e02000, e02100,
e02300, e00400, e02400, c02900, e03210, e03230, e03240,
c01000, c23650, ymod, ymod1, invinc_agi_ec):
Expand Down Expand Up @@ -249,9 +250,12 @@ def CapGains(p23250, p22250, sep, ALD_StudentLoan_hc,
p22250 + ALD_InvInc_ec_rt * p23250))
invinc_agi_ec = ALD_InvInc_ec_rt * (e00300 + e00650) + CG_ec_RyanBrady
# compute ymod1 variable that is included in AGI
ymod1 = (e00200 + e00700 + e00800 + e00900 + e01400 + e01700 +
invinc - invinc_agi_ec +
e02000 + e02100 + e02300)
ymod1 = (e00200 + e00700 + e00800 + e01400 + e01700 +
invinc - invinc_agi_ec + e02100 + e02300 +
max(e00900 + e02000, -ALD_BusinessLosses_c[MARS - 1]))
# compute loss limitation to be added onto ymod1
loss_limit = min(e00900 + e02000 + ALD_BusinessLosses_c[MARS - 1], 0.)
c02900_in_ei = c02900_in_ei + loss_limit
if CG_nodiff:
# apply QDIV+CG exclusion if QDIV+LTCG receive no special tax treatment
qdcg_pos = max(0., e00650 + c01000)
Expand All @@ -263,7 +267,7 @@ def CapGains(p23250, p22250, sep, ALD_StudentLoan_hc,
ymod2 = e00400 + (0.50 * e02400) - c02900
ymod3 = (1. - ALD_StudentLoan_hc) * e03210 + e03230 + e03240
ymod = ymod1 + ymod2 + ymod3
return (c01000, c23650, ymod, ymod1, invinc_agi_ec)
return (c01000, c23650, ymod, ymod1, invinc_agi_ec, c02900_in_ei)


@iterate_jit(nopython=True)
Expand Down Expand Up @@ -709,17 +713,21 @@ def StdDed(DSI, earned, STD, age_head, age_spouse, STD_Aged, STD_Dep,


@iterate_jit(nopython=True)
def TaxInc(c00100, standard, c04470, c04600, c04800,
PT_exclusion_rt, PT_exclusion_wage_limit, e00900,
e26270, e00200):
def TaxInc(c00100, standard, c04470, c04600, c04800, MARS,
PT_excl_rt, PT_excl_wagelim_rt, PT_excl_wagelim_thd,
PT_excl_wagelim_prt, e00900, e26270, e00200):
"""
TaxInc function: ...
"""
pt_exclusion = max(0., PT_exclusion_rt * (e00900 + e26270))
if e26270 > 0.:
pt_exclusion = min(pt_exclusion, e00200 * PT_exclusion_wage_limit)
c04800 = max(0., c00100 - max(c04470, standard) - c04600 -
pt_exclusion)
pt_excl_pre = max(0., PT_excl_rt * (e00900 + e26270))
wagelim_pre = e00200 * PT_excl_wagelim_rt
taxinc_pre = max(0., c00100 - max(c04470, standard) - c04600)
# calculate business income exclusion
excess = max(taxinc_pre - PT_excl_wagelim_thd[MARS - 1], 0.)
wagelim_rt = min(excess * PT_excl_wagelim_prt[MARS - 1], 1.)
limit = wagelim_rt * max(pt_excl_pre - wagelim_pre, 0.)
pt_excl = pt_excl_pre - limit
c04800 = max(0., taxinc_pre - pt_excl)
return c04800


Expand Down
13 changes: 11 additions & 2 deletions taxcalc/reforms/TCJA_Reconciliation.json
Original file line number Diff line number Diff line change
Expand Up @@ -102,12 +102,18 @@
"_PT_brk6":
{"2018": [[500000, 600000, 300000, 500000, 500000]],
"2026": [[504406, 567457, 283728, 535931, 567457]]},
"_PT_exclusion_rt":
"_PT_excl_rt":
{"2018": [0.2],
"2026": [0.0]},
"_PT_exclusion_wage_limit":
"_PT_excl_wagelim_rt":
{"2018": [0.5],
"2026": [9e+99]},
"_PT_excl_wagelim_thd":
{"2018": [[157500, 315000, 157500, 157500, 315000]],
"2026": [[0, 0, 0, 0, 0]]},
"_PT_excl_wagelim_prt":
{"2018": [[0.00002, 0.00001, 0.00002, 0.00002, 0.00001]],
"2026": [[0, 0, 0, 0, 0]]},
"_STD":
{"2018": [[12000, 24000, 12000, 18000, 24000]],
"2026": [[7655, 15311, 7655, 11272, 15311]]},
Expand Down Expand Up @@ -147,6 +153,9 @@
"_ALD_Alimony_hc":
{"2019": [1],
"2026": [0]},
"_ALD_BusinessLosses_c":
{"2018": [[250000, 500000, 250000, 250000, 500000]],
"2026": [[9e99, 9e99, 9e99, 9e99, 9e99]]},
"_ID_prt":
{"2018": [0],
"2026": [0.03]},
Expand Down
6 changes: 3 additions & 3 deletions taxcalc/reforms/TCJA_Senate.json
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
// - Adopt Chained CPI for parameter indexing (9)
// Reform_Parameter_Map:
// - 1: _II_rt*
// - 2: _PT_rt*
// - 2: _PT_*
// - 3: _STD, _STD_Dep, _STD_Aged
// - 4: _II_em
// - 5: _DependentCredit_*, _CTC_c, _CTC_ps, _ACTC_Income_thd
Expand Down Expand Up @@ -75,9 +75,9 @@
{"2018": [[200000, 390000, 195000, 200000, 390000]]},
"_PT_brk6":
{"2018": [[500000, 1000000, 500000, 500000, 1000000]]},
"_PT_exclusion_rt":
"_PT_excl_rt":
{"2018": [0.174]},
"_PT_exclusion_wage_limit":
"_PT_excl_wagelim_rt":
{"2018": [0.5]},
"_STD":
{"2018": [[12000, 24000, 12000, 18000, 24000]]},
Expand Down
6 changes: 3 additions & 3 deletions taxcalc/reforms/TCJA_Senate_111417.json
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
// - Changes to itemized deductions (8)
// Reform_Parameter_Map:
// - 1: _II_rt*
// - 2: _PT_rt*
// - 2: _PT_*
// - 3: _STD (can safely ignore WARNINGs about 2026+ values)
// - 4: _II_em
// - 5: _DependentCredit_*, _CTC_c, _CTC_ps, _ACTC_Income_thd
Expand Down Expand Up @@ -103,10 +103,10 @@
"_PT_brk6":
{"2018": [[500000, 1000000, 500000, 500000, 1000000]],
"2026": [[504406, 567457, 283728, 535931, 567457]]},
"_PT_exclusion_rt":
"_PT_excl_rt":
{"2018": [0.174],
"2026": [0.0]},
"_PT_exclusion_wage_limit":
"_PT_excl_wagelim_rt":
{"2018": [0.5],
"2026": [9e+99]},
"_STD":
Expand Down
4 changes: 2 additions & 2 deletions taxcalc/reforms/TCJA_Senate_120117.json
Original file line number Diff line number Diff line change
Expand Up @@ -101,10 +101,10 @@
"_PT_brk6":
{"2018": [[500000, 1000000, 500000, 500000, 1000000]],
"2026": [[504406, 567457, 283728, 535931, 567457]]},
"_PT_exclusion_rt":
"_PT_excl_rt":
{"2018": [0.23],
"2026": [0.0]},
"_PT_exclusion_wage_limit":
"_PT_excl_wagelim_rt":
{"2018": [0.5],
"2026": [9e+99]},
"_STD":
Expand Down

0 comments on commit 85d9d81

Please sign in to comment.