Zip code (zcta) To County Crosswalk

Maps Cenus zip-code tabulation areas to Counties

census.gov-zcta_county-1.1.1. Modified 2020-11-09T22:28:02

Resources | Packages | Documentation| Contacts| References| Data Dictionary

Resources

Documentation

This file links Ztca regions — the Census version of ZIP codes, to counties, by associating a Zcta with the county that contains the Zctas centroid.

There are only about 1/2 the number of Zctas in this file ( 33K ) as there are ZIP codes ( about 77K )

Contacts

Data Dictionary

county_zcta

county_zcta

Column NameData TypeDescription
stateintegerState FIPS code
countyintegerCounty FIPS code
zctaintegerZcta (zip) code
zcta_geoidstringZcta geoid
county_geoidstringCounty geoid

References

Urls used in the creation of this data package.

  • censusgeo://2018/5/CA/zcta/. ZCTA Geography file
  • censusgeo://2018/5/US/county/. Counties geography file

Packages

Accessing Data in Vanilla Pandas

import pandas as pd


county_zcta_df =  pd.read_csv('http://library.metatab.org/census.gov-zcta_county-1.1.1/data/county_zcta.csv')

Accessing Package in Metapack

import metapack as mp
pkg = mp.open_package('http://library.metatab.org/census.gov-zcta_county-1.1.1.csv')

# Create Dataframes
county_zcta_df = pkg.resource('county_zcta').dataframe()