Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -8,4 +8,4 @@ repos:
rev: v2.1.0
hooks:
- id: flake8
args: ["--max-line-length=100", "--ignore=F841,E203,W503"]
args: ["--max-line-length=105", "--ignore=F841,E203,W503"]
2 changes: 1 addition & 1 deletion cps_stage1/stage1.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@

def main(syr=2014):
SYR = str(syr) # Start year of CPS
EYR = 2030 # Last year in our extrapolation
EYR = 2031 # Last year in our extrapolation

# Read in state SOI estimates
soi_estimates = pd.read_csv(
Expand Down
48 changes: 24 additions & 24 deletions cps_stage1/stage_2_targets.csv
Original file line number Diff line number Diff line change
@@ -1,24 +1,24 @@
,2014,2015,2016,2017,2015,2016,2017,2018,2019,2020,2021,2022,2023,2024,2025,2026,2027,2028,2029,2030
Single,69579590,71086947,71410690,73021932,72028792,71924422,73183813,74331876,75333822,76224441,77122018,77984804,78861507,79745168,80635787,81540322,82451814,83377223,84309589,85248914
Joint,55128595,57272012,57201828,57987204,57069122,56986429,57984256,58893878,59687730,60393376,61104535,61788129,62482750,63182883,63888529,64605200,65327385,66060595,66799319,67543555
HH,22077498,22134303,21659639,21894095,22854626,22821510,23221112,23585391,23903307,24185899,24470699,24744460,25022636,25303020,25585612,25872620,26161835,26455466,26751304,27049351
SS_return,27401498,28087514,28329015,28967603,31684352,32736570,33818929,34953351,36139836,37386604,38614191,39891101,41154310,42384637,43664287,44875433,46007115,47097695,48141692,49089784
Dep_return,96916673,96505181,94809260,94708629,99911398,100735190,101549290,102373082,103187182,104001282,104805690,105610099,106414507,107209224,107984557,108759890,109525532,110281482,111018049,111744924
INTS,156367939,95881223,96640233,106055367,124828526,125813644,138072890,151520533,153099849,148314990,143373763,141153339,141168975,142154093,146985863,155382821,167657704,185561833,205295467,227077521
DIVS,254702232,260252720,254065327,282336042,340613295,332513764,369521998,401410718,416056096,399627802,342549032,361575289,385975762,411700688,440303748,469390743,498223036,527233620,555938562,584592563
SCHCI,374659000,391975736,389078638,416010104,435503622,432281554,462216808,487656154,507850274,496985164,489417052,506913627,528306656,553333877,579222814,605336546,631337881,658238397,686150493,714999236
SCHCL,57400238,60161435,60996610,69637956,63668344,64552308,73696166,77754362,80974516,79241029,78029884,80819535,84234849,88224166,92351243,96512760,100662797,104944855,109399114,113996873
CGNS,705007630,713598090,634341278,859894631,1249696525,1110880523,1505896298,1666144532,1790225875,1756667512,1749758437,1740804840,1709361500,1706752971,1723673155,1756033005,1801999502,1855580082,1915505731,1980507434
Pension,663223262,689991999,693626543,729187412,776568117,800178866,847930940,895152437,934813188,964989846,939190461,971622079,1011282830,1054723954,1103669830,1157125625,1213632247,1274184531,1335400038,1398472570
SCHEI,846331543,891134646,882933054,973306129,1140431754,1129937243,1245546132,1288201242,1288201242,1245207599,1295648959,1394585117,1472532252,1580693423,1685892434,1768579025,1836370182,1887827140,1930228350,1980838976
SCHEL,166947674,177896945,176446339,206369393,169401805,168032834,196514107,203242098,203242098,196464023,204427427,220037034,232324383,249386435,265981034,279036342,289737688,297851345,304529252,312526046
SS,575126918,605152093,619856114,644989570,709246515,726500323,755946821,795975655,847794590,899095911,952065100,1010555508,1073244342,1140131602,1210354599,1284603484,1362935770,1448169580,1536106485,1629392071
UCOMP,33288898,27225383,25420264,23946035,9810238,9161105,8628482,7962704,7490002,7746327,8282278,9484007,11468025,12676412,13075879,13811564,14267622,14727008,15296249,15719018
wage1,114320683,112017897,111270085,107376379,132211870,134189618,140763057,147862371,154778773,150023032,155110303,162175321,168714464,175825210,183610449,191978723,200667095,209126825,217060681,225040264
wage2,261995646,261659142,253415638,247511878,302997965,307530489,322595239,338865169,354715905,343816886,355475692,371667023,386653174,402949304,420791207,439969288,459880957,479268635,497451133,515738429
wage3,381259619,383184602,382875414,382789227,440926749,447522541,469444969,493121191,516187398,500326998,517293051,540854896,562662946,586377294,612341074,640249278,669225009,697438221,723897639,750509560
wage4,418567676,428313928,436140082,441282302,484073517,491314738,515382379,541375432,566698777,549286361,567912623,593780105,617722176,643757086,672261544,702900698,734711842,765685850,794734446,823950470
wage5,418379915,424369612,426147995,437485582,483856372,491094344,515151189,541132582,566444567,549039962,567657869,593513747,617445079,643468309,671959981,702585391,734382265,765342379,794377945,823580863
wage6,916618937,952347137,962308451,1000500360,1060069801,1075927308,1128632897,1185554933,1241010379,1202879031,1243668574,1300315624,1352746227,1409759925,1472181675,1539278181,1608941220,1676771021,1740384376,1804364377
wage7,840581301,835434509,852517230,870406373,972132275,986674331,1035007756,1087207855,1138063023,1103094841,1140500709,1192448634,1240529884,1292814041,1350057628,1411588179,1475472358,1537675374,1596011716,1654684291
wage8,3433224075,3714896131,3792750634,4090211841,3970523643,4029918419,4227328804,4440532019,4648242075,4505419954,4658198425,4870371673,5066752090,5280298627,5514101187,5765413189,6026338219,6280396800,6518662551,6758301592
,2014,2015,2016,2017,2015,2016,2017,2018,2019,2020,2021,2022,2023,2024,2025,2026,2027,2028,2029,2030,2031
Single,69579590,71086947,71410690,73021932,72028792,71924422,73183813,74331876,75333822,76224441,77122018,77984804,78861507,79745168,80635787,81540322,82451814,83377223,84309589,85248914,86209112
Joint,55128595,57272012,57201828,57987204,57069122,56986429,57984256,58893878,59687730,60393376,61104535,61788129,62482750,63182883,63888529,64605200,65327385,66060595,66799319,67543555,68304329
HH,22077498,22134303,21659639,21894095,22854626,22821510,23221112,23585391,23903307,24185899,24470699,24744460,25022636,25303020,25585612,25872620,26161835,26455466,26751304,27049351,27354020
SS_return,27401498,28087514,28329015,28967603,31684352,32736570,33818929,34953351,36139836,37386604,38614191,39891101,41154310,42384637,43664287,44875433,46007115,47097695,48141692,49089784,49843325
Dep_return,96916673,96505181,94809260,94708629,99911398,100735190,101549290,102373082,103187182,104001282,104805690,105610099,106414507,107209224,107984557,108759890,109525532,110281482,111018049,111744924,112452416
INTS,156367939,95881223,96640233,106055367,124828526,125813644,138072890,143655226,146798221,143373763,136337206,132381097,133538220,135633550,142779565,155961382,171410535,189127022,206718415,226311318,245919858
DIVS,254702232,260252720,254065327,282336042,340613295,332513764,369521998,415419340,410732819,401436188,428332744,459890350,480699522,498630560,515211675,530315517,546769281,566254002,589151733,615589825,644549468
SCHCI,374659000,391975736,389078638,416010104,435503622,432281554,462216808,485970189,506464036,507475616,560227603,562438091,582894472,609794988,637220027,663708418,689372560,715898417,741824820,768275745,796937159
SCHCL,57400238,60161435,60996610,69637956,63668344,64552308,73696166,77478841,80750655,80911375,89320510,89670652,92936725,97224523,101592681,105823079,109909976,114140373,118278930,122497848,127066907
CGNS,705007630,713598090,634341278,859894631,1249696525,1110880523,1505896298,1631599158,1805454040,1662689995,2059679791,2087175089,1929182879,1850927032,1823784238,1820118198,1837390885,1872641267,1920017780,1975501880,2039305071
Pension,663223262,689991999,693626543,729187412,776568117,800178866,851446024,896810495,931961328,988401627,1005114854,1022690270,1061621475,1106256401,1155732856,1208392783,1260920066,1318355200,1376984137,1438332288,1506246350
SCHEI,846331543,891134646,882933054,973306129,1140431754,1129937243,1245546132,1321292805,1325778362,1199844229,1356077031,1378081651,1473632483,1584501915,1685553901,1751906294,1807764176,1860659897,1908562263,1956972427,2009275716
SCHEL,166947674,177896945,176446339,206369393,169401805,168032834,196514107,208467561,209168741,189301968,213960139,217432651,232508026,249987447,265930950,276398569,285213406,293560790,301123520,308753028,317000243
SS,575126918,605152093,619856114,644989570,709246515,726500323,755946821,795975655,847794590,899095911,952065100,1010555508,1073244342,1140131602,1210354599,1284603484,1362935770,1448169580,1536106485,1629392071,1728256389
UCOMP,33288898,27225383,25420264,23946035,9810238,9161105,8628482,7962704,7490002,7746327,66767543,11068559,10216363,9960038,9417429,9151118,9347523,9880145,10459372,11185070,12559901
wage1,114320683,112017897,111270085,107376379,132211870,134189618,140763057,147793779,154687316,155144599,162735492,170189201,177414268,185268099,193430596,201364451,208760999,216306164,223908490,231579408,239753336
wage2,261995646,261659142,253415638,247511878,302997965,307530489,322595239,338707971,354506309,355554291,372950802,390032918,406591043,424590144,443296633,461479131,478430249,495721962,513144672,530724580,549457269
wage3,381259619,383184602,382875414,382789227,440926749,447522541,469444969,492892435,515882390,517407429,542723068,567581195,591676803,617869339,645091275,671550693,696218190,721381325,746735090,772317610,799577673
wage4,418567676,428313928,436140082,441282302,484073517,491314738,515382379,541124292,566363922,568038193,595831087,623121699,649575176,678330776,708216508,737265105,764346433,791971900,819806650,847892541,877820130
wage5,418379915,424369612,426147995,437485582,483856372,491094344,515151189,540881554,566109863,567783383,595563809,622842179,649283790,678026490,707898816,736934382,764003563,791616637,819438902,847512194,877426358
wage6,916618937,952347137,962308451,1000500360,1060069801,1075927308,1128632897,1185004962,1240277084,1243943559,1304807057,1364570612,1422500928,1485472649,1550919241,1614532596,1673837841,1734334691,1795289850,1856794981,1922333235
wage7,840581301,835434509,852517230,870406373,972132275,986674331,1035007756,1086703506,1137390558,1140752884,1196567482,1251373383,1304498121,1362246056,1422263561,1480599904,1534985514,1590463880,1646362536,1702765541,1762867104
wage8,3433224075,3714896131,3792750634,4090211841,3970523643,4029918419,4227328804,4438472084,4645495496,4659228392,4887194471,5111040680,5328020442,5563882936,5809015135,6047280886,6269410483,6496003272,6724312673,6954682009,7200157530
Binary file modified cps_stage2/cps_weights.csv.gz
Binary file not shown.
2 changes: 1 addition & 1 deletion cps_stage2/solver.jl
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,7 @@ function Solve_func(year, tol)

end

year_list = [x for x in 2014:2030]
year_list = [x for x in 2014:2031]
tol = 0.70

# Run solver function for all years and tolerances (in order)
Expand Down
2 changes: 1 addition & 1 deletion cps_stage2/stage2.py
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
STAGE_1_PATH = Path(CUR_PATH, "..", "puf_stage1", "Stage_I_factors.csv")
STAGE_2_PATH = Path(CUR_PATH, "..", "cps_stage1", "stage_2_targets.csv")
START_YEAR = 2014
END_YEAR = 2030
END_YEAR = 2031


def main():
Expand Down
14 changes: 7 additions & 7 deletions doc/CBO_Baseline_Updating_Instructions.md
Original file line number Diff line number Diff line change
Expand Up @@ -47,9 +47,9 @@ As previously mentioned, most of the variables we used can be found in the
To manually update these variables download the latest file and copy/paste the
specific variables.

Previous Document: January 2020
Previous Document: July 2020

Current Document: July 2020
Current Document: February 2021

| Variable | Name In CBO Document |
|----------|-----------------------------------------------------|
Expand All @@ -70,9 +70,9 @@ Current Document: July 2020

Source: [Revenue Projections, By Category (CBO)](https://www.cbo.gov/about/products/budget-economic-data#7)

Previous: [January 2019](https://www.cbo.gov/system/files/2019-02/51138-2019-01-revenueprojections.xlsx)
Previous: [January 2020](https://www.cbo.gov/system/files/2020-01/51138-2020-01-revenue-projections.xlsx)

Current: [January 2020](https://www.cbo.gov/system/files/2020-01/51138-2020-01-revenue-projections.xlsx)
Current: [February 2021](https://www.cbo.gov/system/files/2021-02/51138-2021-02-11-revenueprojections.xlsx)

In the revenue projections file, the data is in the `Capital Gains Realizations`
tab under the `Capital Gains Realizations` column.
Expand All @@ -81,9 +81,9 @@ tab under the `Capital Gains Realizations` column.

Source: [IRS Publication 6187 Table 1B](https://www.irs.gov/statistics/projections-of-federal-tax-return-filings)

Previous: [Fall 2019 Update](https://www.irs.gov/pub/irs-pdf/p6187.pdf)
Previous: [Fall 2019 Report](https://www.irs.gov/pub/irs-soi/19projpub6187tables.xls)

Current: [Fall 2019 Report](https://www.irs.gov/pub/irs-soi/19projpub6187tables.xls)
Current: [Fall 2020 Report](https://www.irs.gov/pub/irs-soi/20projpub6187tables.xls)

The projections in the publication typically end a few years before the
10-year projections do. We use the growth rate from the final year in the
Expand All @@ -108,7 +108,7 @@ column of this table.
Source: [BLS Database](http://data.bls.gov/timeseries/CUSR0000SAM?output_view=pct_1mth)

Series ID: CUSR0000SAM
Access Date: August 22 2020
Access Date: June 16 2021

Manual Instructions:

Expand Down
Binary file added history/reports/taxdata_report_2021-06-16.pdf
Binary file not shown.
32 changes: 16 additions & 16 deletions puf_stage1/CBO_baseline.csv
Original file line number Diff line number Diff line change
@@ -1,16 +1,16 @@
,2008,2009,2010,2011,2012,2013,2014,2015,2016,2017,2018,2019,2020,2021,2022,2023,2024,2025,2026,2027,2028,2029,2030
GDP,14718.6,14418.7,14964.4,15517.9,16163.2,16800.0,17348.1,18036.7,18624.5,19519.4,20580.3,21427.7,20339.1,21313.0,22298.0,23208.5,24213.7,25286.6,26415.3,27582.8,28746.8,29873.5,31022.3
TPY,12429.6,12087.5,12429.3,13202.0,13887.7,14166.9,14694.2,15458.5,15928.7,16878.8,17819.2,18608.3,19208.3,18695.7,19341.5,20130.6,20995.7,21969.5,23033.8,24157.9,25364.3,26582.2,27837.8
Wages,6531.9,6251.4,6377.5,6633.2,6932.1,7124.7,7477.8,7854.8,8085.3,8462.1,8888.5,9304.2,9018.2,9324.6,9748.8,10141.9,10569.3,11037.6,11540.5,12062.9,12571.5,13048.6,13528.3
SCHC,979.5,937.5,986.7,1068.1,1187.9,1253.5,1268.5,1336.8,1298.7,1480.1,1561.6,1626.3,1591.5,1567.2,1623.2,1691.8,1771.9,1854.8,1938.4,2021.7,2107.8,2197.2,2289.6
SCHF,47.0,35.5,46.0,75.5,72.3,83.2,78.1,40.0,43.2,38.1,27.2,32.0,28.7,30.6,34.7,37.6,40.4,43.0,45.3,47.8,50.5,53.6,56.9
INTS,1361.6,1264.3,1195.0,1231.6,1255.9,1255.2,1302.0,1302.8,1415.3,1551.6,1702.7,1720.6,1666.8,1611.3,1586.3,1586.4,1597.5,1651.8,1746.1,1884.2,2085.4,2307.0,2551.8
DIVS,805.4,553.7,544.6,682.2,832.7,824.5,815.5,951.1,962.5,1130.0,1227.5,1272.3,1222.1,1047.5,1105.7,1180.3,1259.0,1346.5,1435.4,1523.6,1612.3,1700.1,1787.7
RENTS,262.1,333.7,402.8,485.3,533.0,595.8,610.8,659.6,707.4,718.8,756.8,777.9,802.8,807.1,849.7,903.1,946.7,978.8,1005.7,1029.5,1054.5,1080.9,1108.8
CGNS,498.0,264.0,394.0,404.0,647.0,511.0,716.0,725.0,641.0,871.3,964.0,1035.8,1016.4,1012.4,1007.2,989.0,987.5,997.3,1016.0,1042.6,1073.6,1108.3,1145.9
BOOK,1285.1,1397.0,1746.4,1816.6,2022.8,2106.9,2072.9,2088.1,2073.5,2006.0,2074.6,2074.7,2005.4,2086.7,2246.0,2371.5,2545.7,2715.1,2848.3,2957.5,3040.3,3108.6,3190.2
RETS,142.5,140.5,142.9,145.4,144.9,146.6,148.3,147.8,149.7,149.9,152.5,153.6,155.1,156.6,158.0,159.5,161.0,162.4,163.9,165.4,166.9,168.4,169.9
SOCSEC,503.0,544.5,572.5,591.5,627.2,663.2,698.2,733.7,762.1,791.1,833.0,887.2,940.9,996.3,1057.5,1123.1,1193.1,1266.6,1344.3,1426.3,1515.5,1607.5,1705.1
CPIU,215.3,214.5,218.1,224.9,229.6,233.0,236.7,237.0,240.0,245.1,251.1,255.6,258.1,261.2,266.0,271.8,277.9,284.2,290.5,297.0,303.6,310.4,317.3
CPIM,364.1,375.6,388.4,400.3,414.9,425.1,435.3,446.8,463.7,475.3,484.7,498.4,516.8,463.5,468.3,474.1,480.2,486.5,492.8,499.3,505.9,512.7,519.6
UCOMP,51.1,131.2,138.9,107.2,83.6,62.2,43.8,39.9,31.2,31.1,28.7,27.0,27.925,29.855,34.185,41.335,45.685,47.125,49.78,51.42,53.08,55.135,56.655
,2008,2009,2010,2011,2012,2013,2014,2015,2016,2017,2018,2019,2020,2021,2022,2023,2024,2025,2026,2027,2028,2029,2030,2031
GDP,14718.6,14418.7,14964.4,15517.9,16163.2,16800,17348.1,18036.7,18624.5,19543,20611.9,21433.2,20933.5,22253.1,23334.8,24322,25402.1,26529.2,27630.3,28689.4,29783.9,30903,32039.8,33237.6
TPY,12429.6,12087.5,12429.3,13202,13887.7,14166.9,14694.2,15458.5,15928.7,16948.6,17851.9,18551.5,19675.2,20007.9,20357.1,21132.1,22020.3,23006.2,24053.4,25099.9,26242.6,27410.3,28631.6,29983.7
Wages,6531.9,6251.4,6377.5,6633.2,6932.1,7124.7,7477.8,7854.8,8085.3,8471.5,8894.2,9309.4,9336.7,9793.5,10241.9,10676.8,11149.9,11641.1,12118.2,12563.6,13017.3,13475.2,13936.8,14428.2
SCHC,979.5,937.5,986.7,1068.1,1187.9,1253.5,1268.5,1336.8,1298.7,1467.5,1542.9,1608,1611.2,1778.7,1785.7,1850.7,1936.1,2023.1,2107.3,2188.7,2272.9,2355.3,2439.3,2530.3
SCHF,47,35.5,46,75.5,72.3,83.2,78.1,40,43.2,41.5,43,49.7,66.4,62,54.7,58,59.9,61.7,63.3,65.2,67.2,69.6,72.2,74.8
INTS,1361.6,1264.3,1195,1231.6,1255.9,1255.2,1302,1302.8,1415.3,1577.7,1641.6,1677.4,1638.3,1557.9,1512.7,1526,1549.8,1631.6,1782.2,1958.7,2161.2,2362.2,2586.1,2810.1
DIVS,805.4,553.7,544.6,682.2,832.7,824.5,815.5,951.1,962.5,1160.9,1305.1,1290.4,1261.2,1345.7,1444.8,1510.2,1566.5,1618.6,1666.1,1717.8,1779,1850.9,1934,2025
RENTS,262.1,333.7,402.8,485.3,533,595.8,610.8,659.6,707.4,721.9,759.3,787.1,804.4,837.7,888.3,948.7,993.8,1019.4,1039.9,1061,1091.7,1127.6,1165.3,1215.5
CGNS,498,264,394,404,647,511,716,725,641,871.3,944,1044.6,962,1191.7,1207.6,1116.2,1070.9,1055.2,1053.1,1063.1,1083.5,1110.9,1143,1179.9
BOOK,1285.1,1397,1746.4,1816.6,2022.8,2106.9,2072.9,2088.1,2073.5,2114.5,2243,2250.6,2036.8,2302.1,2339.5,2501.7,2689.8,2861.4,2974,3068.9,3158.6,3240,3322.1,3410.9
RETS,142.5,140.5,142.9,145.4,144.9,146.6,148.3,147.8,149.7,149.9,152.5,153.5,160,161,159.1,161.8,164.2,165.9,167.2,168.3,169.5,170.8,172,173.2
SOCSEC,503,544.5,572.5,591.5,627.2,663.2,698.2,733.7,762.1,791.1,833,887.2,940.9,996.3,1057.5,1123.1,1193.1,1266.6,1344.3,1426.3,1515.5,1607.5,1705.1,1808.6
CPIU,215.3,214.5,218.1,224.9,229.6,233,236.7,237,240,245.1,251.1,255.6,258.8,263.8,269.3,275.4,281.8,288.4,295.4,302.6,310,317.6,325.2,332.8
CPIM,364.1,375.6,388.4,400.3,414.9,425.1,435.3,446.8,463.7,475.3,484.7,498.4,518.9,523.2,475.8,481.9,488.3,494.9,501.9,509.1,516.5,524.1,531.7,539.3
UCOMP,51.1,131.2,138.9,107.2,83.6,62.2,43.8,39.9,31.2,31.1,28.7,27,27.925,240.656,39.895,36.821,35.901,33.945,32.98,33.692,35.617,37.695,40.32,45.273
Loading