IRS SOI ZIP Code Data 2017 – Individual Income Tax Statistics (with AGI)
- Rows
- 166,537
- Columns
- 153
- Data range
- 0 to 99999
Tax Year 2017 individual income tax statistics by ZIP code and AGI class. All states. First year reflecting TCJA transition data; includes returns, AGI, wages, dividends, interest, and tax liability.
AI analysis
IRS SOI ZIP Code Data 2017 – Analytical Overview
1. Dataset Representation and Research Value
This dataset originates from the IRS Statistics of Income (SOI) division, published at [https://www.irs.gov/pub/irs-soi/17zpallagi.csv](https://www.irs.gov/pub/irs-soi/17zpallagi.csv), a highly authoritative federal source with consistent annual releases. The 2017 edition carries particular analytical significance as the first tax year reflecting TCJA (Tax Cuts and Jobs Act) transition effects, making it a natural baseline for studying how federal tax reform altered behavior across income strata and geographies. With 166,537 rows spanning 153 columns, the dataset captures individual income tax statistics aggregated at the ZIP code × AGI income class level — six AGI stubs (1–6, from under $1 to $500K+) crossed against roughly 27,660 unique ZIP codes. This dual granularity makes it exceptionally powerful for studying income inequality, regional economic patterns, deduction behavior, tax credit uptake, and the distributional effects of TCJA across income groups and geographies simultaneously.
---
2. Data Quality Observations
The dataset presents an unusually clean profile for a real-world administrative file of this size. Total null cells across all 153 columns is zero, which reflects the IRS's practice of substituting zeros for suppressed or absent values rather than leaving fields blank — an important interpretation caveat, since a zero in, say, VITA or CPREP may mean "not applicable" rather than "truly measured as zero." The duplicate row count is flagged as pending Phase D recomputation, so deduplication validation against the (zipcode, agistub) composite key should be completed before any aggregation analysis. No type mismatches are reported, and all decimal columns parse cleanly. The primary data quality concern is not missingness but zero-inflation: columns like TOTALVITA (median=0, Q3=0), VITAEIC (median=0, Q3=0), N03300 (median=0, Q3=0), and N09600 (median=0, Q3=0) have the majority of their mass at zero, reflecting that these tax programs apply only to narrow subpopulations. Analysts should treat these as sparse indicators rather than continuous measures. Outlier counts are pervasive and large — mars1 shows 22,903 outliers, A26270 shows 25,877, and A85770 shows 29,485 — consistent with the extreme right-skew of income distributions and the presence of a small number of very large urban ZIP codes.
---
3. Key Column Distributions and Notable Patterns
The primary income variable A00100 (Adjusted Gross Income, in $thousands) exhibits the most analytically important distribution: mean=$132,925 vs. median=$15,772, a ratio of ~8.4×, with σ=$3.1M and skewness=113 — a textbook extreme right-skew driven by the top AGI stub. The Q1–Q3 range of $4,215–$62,469 captures the bulk of the distribution, with 17,640 flagged outliers representing high-income ZIP codes. Its close partner A02650 (total income before adjustments, mean=$134,739, skew=113) tracks nearly identically, confirming internal consistency. Wages (A00200) show mean=$89,717 vs. median=$10,800 (skew=93), while dividends (A00600) are far more concentrated: mean=$3,022 vs. median=$131 with skew=153, indicating dividend income is highly localized to wealthy ZIP codes in high AGI stubs. The capital gains field A01000 is perhaps the most extreme: mean=$8,701, median=$175, skew=180, max=$109.6M — a signal of extraordinary geographic and income-class concentration of investment activity. On the deduction side, A04470 (itemized deductions, mean=$16,502, median=$1,398, skew=153) and A18300 (taxes paid deduction, mean=$7,397, median=$402, skew=204) are directly relevant to TCJA analysis given the new SALT cap. Filing behavior columns like ELF (e-file count, mean=1,595, median=220, skew=77) mirror N1 (total returns, mean=1,798, median=250), confirming e-filing dominance. The ELDERLY column (mean=432, median=70, skew=62) is comparatively less skewed, suggesting elderly filer counts are more evenly distributed geographically.
---
4. Recommended Join Key Columns
The natural composite join key is (zipcode, agistub), which together form a unique row identifier across the ~27,660 ZIP codes × 6 income stubs. zipcode alone (Integer, min=0, max=99,999, 27,660 distinct values, nulls=0) is the primary geographic join key for linking to any ZIP-level dataset — census demographics, housing prices, health outcomes, election results, etc. Note that zipcode=0 rows likely represent state-level aggregates or suppressed geographies and should be filtered or handled separately before spatial joins. STATEFIPS (51 distinct values including DC) and STATE (string, 51 distinct) provide rollup keys for state-level aggregation and joins to state-coded datasets. For income-stratified analysis, agistub (1–6) is essential and should always be included in join logic to avoid mixing income classes. When joining to datasets without income-class granularity, it is recommended to filter to agistub=0 (all returns aggregate) if available, or sum/weight across stubs to reconstruct ZIP-level totals.
---
5. Recommended Paired Datasets for Correlation Discovery
Several dataset categories would unlock high-value correlations with this data. U.S. Census ACS 5-Year Estimates at the ZIP/ZCTA level (demographics, education, race, housing costs) would allow testing whether AGI distributions, EITC uptake (N59660, A59660), and itemized deduction rates correlate with educational attainment or housing tenure — particularly relevant post-TCJA. Zillow or HUD ZIP-level housing price indices would pair naturally with A18500 (mortgage interest deduction) and A18300 (SALT/taxes paid) to measure how housing costs map to deduction behavior before and after the SALT cap. BLS Quarterly Census of Employment and Wages (QCEW) by county/ZIP would let analysts correlate wage income (A00200) and self-employment income (A00900) against local industry mix and unemployment rates. IRS SOI data from adjacent years (2015, 2016, 2018, 2019) are the most direct pairing — diffing A04470, A18300, and N04470 across years by agistub would directly quantify TCJA's itemization impact by income class. Finally, CDC PLACES or county health rankings at the ZIP level would enable exploration of whether tax-credit indicators like VITA, TCE, and EIC (A59660) correlate with health outcome disparities — a potentially powerful equity-focused analysis thread.
Columns
- zipcode (integer)
- agi_stub (integer)
- STATEFIPS (integer)
- STATE (string)
- N1 (decimal)
- mars1 (decimal)
- MARS2 (decimal)
- MARS4 (decimal)
- ELF (decimal)
- CPREP (decimal)
- PREP (decimal)
- DIR_DEP (decimal)
- N2 (decimal)
- NUMDEP (decimal)
- TOTAL_VITA (decimal)
- VITA (decimal)
- TCE (decimal)
- VITA_EIC (decimal)
- RAC (decimal)
- ELDERLY (decimal)
- A00100 (decimal)
- N02650 (decimal)
- A02650 (decimal)
- N00200 (decimal)
- A00200 (decimal)
- N00300 (decimal)
- A00300 (decimal)
- N00600 (decimal)
- A00600 (decimal)
- N00650 (decimal)
- A00650 (decimal)
- N00700 (decimal)
- A00700 (decimal)
- N00900 (decimal)
- A00900 (decimal)
- N01000 (decimal)
- A01000 (decimal)
- N01400 (decimal)
- A01400 (decimal)
- N01700 (decimal)
- A01700 (decimal)
- SCHF (decimal)
- N02300 (decimal)
- A02300 (decimal)
- N02500 (decimal)
- A02500 (decimal)
- N26270 (decimal)
- A26270 (decimal)
- N02900 (decimal)
- A02900 (decimal)
- N03220 (decimal)
- A03220 (decimal)
- N03300 (decimal)
- A03300 (decimal)
- N03270 (decimal)
- A03270 (decimal)
- N03150 (decimal)
- A03150 (decimal)
- N03210 (decimal)
- A03210 (decimal)
- N03230 (decimal)
- A03230 (decimal)
- N03240 (decimal)
- A03240 (decimal)
- N04470 (decimal)
- A04470 (decimal)
- A00101 (decimal)
- N17000 (decimal)
- A17000 (decimal)
- N18425 (decimal)
- A18425 (decimal)
- N18450 (decimal)
- A18450 (decimal)
- N18500 (decimal)
- A18500 (decimal)
- N18800 (decimal)
- A18800 (decimal)
- N18300 (decimal)
- A18300 (decimal)
- N19300 (decimal)
- A19300 (decimal)
- N19500 (decimal)
- A19500 (decimal)
- N19530 (decimal)
- A19530 (decimal)
- N19550 (decimal)
- A19550 (decimal)
- N19570 (decimal)
- A19570 (decimal)
- N19700 (decimal)
- A19700 (decimal)
- N20800 (decimal)
- A20800 (decimal)
- N20950 (decimal)
- A20950 (decimal)
- N04800 (decimal)
- A04800 (decimal)
- N05800 (decimal)
- A05800 (decimal)
- N09600 (decimal)
- A09600 (decimal)
- N05780 (decimal)
- A05780 (decimal)
- N07100 (decimal)
- A07100 (decimal)
- N07300 (decimal)
- A07300 (decimal)
- N07180 (decimal)
- A07180 (decimal)
- N07230 (decimal)
- A07230 (decimal)
- N07240 (decimal)
- A07240 (decimal)
- N07220 (decimal)
- A07220 (decimal)
- N07260 (decimal)
- A07260 (decimal)
- N09400 (decimal)
- A09400 (decimal)
- N85770 (decimal)
- A85770 (decimal)
- N85775 (decimal)
- A85775 (decimal)
- N09750 (decimal)
- A09750 (decimal)
- N10600 (decimal)
- A10600 (decimal)
- N59660 (decimal)
- A59660 (decimal)
- N59720 (decimal)
- A59720 (decimal)
- N11070 (decimal)
- A11070 (decimal)
- N10960 (decimal)
- A10960 (decimal)
- N11560 (decimal)
- A11560 (decimal)
- N06500 (decimal)
- A06500 (decimal)
- N10300 (decimal)
- A10300 (decimal)
- N85530 (decimal)
- A85530 (decimal)
- N85300 (decimal)
- A85300 (decimal)
- N11901 (decimal)
- A11901 (decimal)
- N11900 (decimal)
- A11900 (decimal)
- N11902 (decimal)
- A11902 (decimal)
- N12000 (decimal)
- A12000 (decimal)