update utils/tiger_county_fips.json data

This commit is contained in:
Marc Tobias Metten 2017-10-28 00:08:59 +02:00
parent 6a3c6c43ea
commit 1a1e0ef138
2 changed files with 23 additions and 85 deletions

View File

@ -35,9 +35,10 @@ except:
import ogr
import osr
# tiger_county_fips was generated from the following:
# wget http://www.census.gov/datamap/fipslist/AllSt.txt
# cat AllSt.txt | grep '^ [0-9]' | awk "{printf \"'%s' : '%s' ,\\n\", \$1, substr(\$0, 31)}" | > countyfips.py
# https://www.census.gov/geo/reference/codes/cou.html
# tiger_county_fips.json was generated from the following:
# wget https://www2.census.gov/geo/docs/reference/codes/files/national_county.txt
# cat national_county.txt | perl -F, -naE'($F[0] ne 'AS') && $F[3] =~ s/ ((city|City|County|District|Borough|City and Borough|Municipio|Municipality|Parish|Island|Census Area)(?:, |\Z))+//; say qq( "$F[1]$F[2]": "$F[3], $F[0]",)'
json_fh = open(os.path.dirname(sys.argv[0]) + "/tiger_county_fips.json")
county_fips_data = json.load(json_fh)

View File

@ -1,5 +1,4 @@
{
"01000": "ALABAMA",
"01001": "Autauga, AL",
"01003": "Baldwin, AL",
"01005": "Barbour, AL",
@ -24,7 +23,7 @@
"01043": "Cullman, AL",
"01045": "Dale, AL",
"01047": "Dallas, AL",
"01049": "De Kalb, AL",
"01049": "DeKalb, AL",
"01051": "Elmore, AL",
"01053": "Escambia, AL",
"01055": "Etowah, AL",
@ -67,7 +66,6 @@
"01129": "Washington, AL",
"01131": "Wilcox, AL",
"01133": "Winston, AL",
"02000": "ALASKA",
"02013": "Aleutians East, AK",
"02016": "Aleutians West, AK",
"02020": "Anchorage, AK",
@ -77,28 +75,24 @@
"02070": "Dillingham, AK",
"02090": "Fairbanks North Star, AK",
"02100": "Haines, AK",
"02105": "Hoonah-Angoon Census Area, AK",
"02105": "Hoonah-Angoon, AK",
"02110": "Juneau, AK",
"02122": "Kenai Peninsula, AK",
"02130": "Ketchikan Gateway, AK",
"02150": "Kodiak Island, AK",
"02158": "Kusilvak Census Area, AK",
"02164": "Lake and Peninsula, AK",
"02170": "Matanuska-Susitna, AK",
"02180": "Nome, AK",
"02185": "North Slope, AK",
"02188": "Northwest Arctic, AK",
"02195": "Petersburg, AK",
"02198": "Prince of Wales-Hyder Census Area, AK",
"02201": "Prince of Wales-Outer Ketchikan, AK",
"02198": "Prince of Wales-Hyder, AK",
"02220": "Sitka, AK",
"02230": "Skagway, AK",
"02232": "Skagway-Hoonah-Angoon, AK",
"02240": "Southeast Fairbanks, AK",
"02261": "Valdez-Cordova, AK",
"02270": "Wade Hampton, AK",
"02275": "Wrangell City and Borough, AK",
"02280": "Wrangell-Petersburg, AK",
"02275": "Wrangell, AK",
"02282": "Yakutat, AK",
"02290": "Yukon-Koyukuk, AK",
"04001": "Apache, AZ",
@ -116,7 +110,6 @@
"04023": "Santa Cruz, AZ",
"04025": "Yavapai, AZ",
"04027": "Yuma, AZ",
"05000": "ARKANSAS",
"05001": "Arkansas, AR",
"05003": "Ashley, AR",
"05005": "Baxter, AR",
@ -192,7 +185,6 @@
"05145": "White, AR",
"05147": "Woodruff, AR",
"05149": "Yell, AR",
"06000": "CALIFORNIA",
"06001": "Alameda, CA",
"06003": "Alpine, CA",
"06005": "Amador, CA",
@ -251,7 +243,6 @@
"06111": "Ventura, CA",
"06113": "Yolo, CA",
"06115": "Yuba, CA",
"08000": "COLORADO",
"08001": "Adams, CO",
"08003": "Alamosa, CO",
"08005": "Arapahoe, CO",
@ -259,8 +250,8 @@
"08009": "Baca, CO",
"08011": "Bent, CO",
"08013": "Boulder, CO",
"08015": "Chaffee, CO",
"08014": "Broomfield, CO",
"08015": "Chaffee, CO",
"08017": "Cheyenne, CO",
"08019": "Clear Creek, CO",
"08021": "Conejos, CO",
@ -316,7 +307,6 @@
"08121": "Washington, CO",
"08123": "Weld, CO",
"08125": "Yuma, CO",
"09000": "CONNECTICUT",
"09001": "Fairfield, CT",
"09003": "Hartford, CT",
"09005": "Litchfield, CT",
@ -325,13 +315,10 @@
"09011": "New London, CT",
"09013": "Tolland, CT",
"09015": "Windham, CT",
"10000": "DELAWARE",
"10001": "Kent, DE",
"10003": "New Castle, DE",
"10005": "Sussex, DE",
"11000": "DISTRICT OF COLUMBIA",
"11001": "District of Columbia",
"12000": "FLORIDA",
"11001": "District of Columbia, DC",
"12001": "Alachua, FL",
"12003": "Baker, FL",
"12005": "Bay, FL",
@ -344,8 +331,7 @@
"12019": "Clay, FL",
"12021": "Collier, FL",
"12023": "Columbia, FL",
"12025": "Dade, FL",
"12027": "De Soto, FL",
"12027": "DeSoto, FL",
"12029": "Dixie, FL",
"12031": "Duval, FL",
"12033": "Escambia, FL",
@ -400,7 +386,6 @@
"12129": "Wakulla, FL",
"12131": "Walton, FL",
"12133": "Washington, FL",
"13000": "GEORGIA",
"13001": "Appling, GA",
"13003": "Atkinson, GA",
"13005": "Bacon, GA",
@ -444,7 +429,7 @@
"13083": "Dade, GA",
"13085": "Dawson, GA",
"13087": "Decatur, GA",
"13089": "De Kalb, GA",
"13089": "DeKalb, GA",
"13091": "Dodge, GA",
"13093": "Dooly, GA",
"13095": "Dougherty, GA",
@ -560,13 +545,11 @@
"13317": "Wilkes, GA",
"13319": "Wilkinson, GA",
"13321": "Worth, GA",
"15000": "HAWAII",
"15001": "Hawaii, HI",
"15003": "Honolulu, HI",
"15005": "Kalawao, HI",
"15007": "Kauai, HI",
"15009": "Maui, HI",
"16000": "IDAHO",
"16001": "Ada, ID",
"16003": "Adams, ID",
"16005": "Bannock, ID",
@ -611,7 +594,6 @@
"16083": "Twin Falls, ID",
"16085": "Valley, ID",
"16087": "Washington, ID",
"17000": "ILLINOIS",
"17001": "Adams, IL",
"17003": "Alexander, IL",
"17005": "Bond, IL",
@ -714,7 +696,6 @@
"17199": "Williamson, IL",
"17201": "Winnebago, IL",
"17203": "Woodford, IL",
"18000": "INDIANA",
"18001": "Adams, IN",
"18003": "Allen, IN",
"18005": "Bartholomew, IN",
@ -731,7 +712,7 @@
"18027": "Daviess, IN",
"18029": "Dearborn, IN",
"18031": "Decatur, IN",
"18033": "De Kalb, IN",
"18033": "DeKalb, IN",
"18035": "Delaware, IN",
"18037": "Dubois, IN",
"18039": "Elkhart, IN",
@ -758,9 +739,9 @@
"18081": "Johnson, IN",
"18083": "Knox, IN",
"18085": "Kosciusko, IN",
"18087": "Lagrange, IN",
"18087": "LaGrange, IN",
"18089": "Lake, IN",
"18091": "La Porte, IN",
"18091": "LaPorte, IN",
"18093": "Lawrence, IN",
"18095": "Madison, IN",
"18097": "Marion, IN",
@ -807,7 +788,6 @@
"18179": "Wells, IN",
"18181": "White, IN",
"18183": "Whitley, IN",
"19000": "IOWA",
"19001": "Adair, IA",
"19003": "Adams, IA",
"19005": "Allamakee, IA",
@ -907,7 +887,6 @@
"19193": "Woodbury, IA",
"19195": "Worth, IA",
"19197": "Wright, IA",
"20000": "KANSAS",
"20001": "Allen, KS",
"20003": "Anderson, KS",
"20005": "Atchison, KS",
@ -1013,7 +992,6 @@
"20205": "Wilson, KS",
"20207": "Woodson, KS",
"20209": "Wyandotte, KS",
"21000": "KENTUCKY",
"21001": "Adair, KY",
"21003": "Allen, KY",
"21005": "Anderson, KY",
@ -1134,7 +1112,6 @@
"21235": "Whitley, KY",
"21237": "Wolfe, KY",
"21239": "Woodford, KY",
"22000": "LOUISIANA",
"22001": "Acadia, LA",
"22003": "Allen, LA",
"22005": "Ascension, LA",
@ -1164,7 +1141,7 @@
"22053": "Jefferson Davis, LA",
"22055": "Lafayette, LA",
"22057": "Lafourche, LA",
"22059": "LaSalle, LA",
"22059": "La Salle, LA",
"22061": "Lincoln, LA",
"22063": "Livingston, LA",
"22065": "Madison, LA",
@ -1199,7 +1176,6 @@
"22123": "West Carroll, LA",
"22125": "West Feliciana, LA",
"22127": "Winn, LA",
"23000": "MAINE",
"23001": "Androscoggin, ME",
"23003": "Aroostook, ME",
"23005": "Cumberland, ME",
@ -1216,7 +1192,6 @@
"23027": "Waldo, ME",
"23029": "Washington, ME",
"23031": "York, ME",
"24000": "MARYLAND",
"24001": "Allegany, MD",
"24003": "Anne Arundel, MD",
"24005": "Baltimore, MD",
@ -1240,8 +1215,7 @@
"24043": "Washington, MD",
"24045": "Wicomico, MD",
"24047": "Worcester, MD",
"24510": "Baltimore City, MD",
"25000": "MASSACHUSETTS",
"24510": "Baltimore, MD",
"25001": "Barnstable, MA",
"25003": "Berkshire, MA",
"25005": "Bristol, MA",
@ -1256,7 +1230,6 @@
"25023": "Plymouth, MA",
"25025": "Suffolk, MA",
"25027": "Worcester, MA",
"26000": "MICHIGAN",
"26001": "Alcona, MI",
"26003": "Alger, MI",
"26005": "Allegan, MI",
@ -1340,7 +1313,6 @@
"26161": "Washtenaw, MI",
"26163": "Wayne, MI",
"26165": "Wexford, MI",
"27000": "MINNESOTA",
"27001": "Aitkin, MN",
"27003": "Anoka, MN",
"27005": "Becker, MN",
@ -1428,7 +1400,6 @@
"27169": "Winona, MN",
"27171": "Wright, MN",
"27173": "Yellow Medicine, MN",
"28000": "MISSISSIPPI",
"28001": "Adams, MS",
"28003": "Alcorn, MS",
"28005": "Amite, MS",
@ -1511,7 +1482,6 @@
"28159": "Winston, MS",
"28161": "Yalobusha, MS",
"28163": "Yazoo, MS",
"29000": "MISSOURI",
"29001": "Adair, MO",
"29003": "Andrew, MO",
"29005": "Atchison, MO",
@ -1543,7 +1513,7 @@
"29057": "Dade, MO",
"29059": "Dallas, MO",
"29061": "Daviess, MO",
"29063": "De Kalb, MO",
"29063": "DeKalb, MO",
"29065": "Dent, MO",
"29067": "Douglas, MO",
"29069": "Dunklin, MO",
@ -1626,8 +1596,7 @@
"29225": "Webster, MO",
"29227": "Worth, MO",
"29229": "Wright, MO",
"29510": "St. Louis City, MO",
"30000": "MONTANA",
"29510": "St. Louis, MO",
"30001": "Beaverhead, MT",
"30003": "Big Horn, MT",
"30005": "Blaine, MT",
@ -1684,8 +1653,6 @@
"30107": "Wheatland, MT",
"30109": "Wibaux, MT",
"30111": "Yellowstone, MT",
"30113": "Yellowstone National Park, MT",
"31000": "NEBRASKA",
"31001": "Adams, NE",
"31003": "Antelope, NE",
"31005": "Arthur, NE",
@ -1779,7 +1746,6 @@
"31181": "Webster, NE",
"31183": "Wheeler, NE",
"31185": "York, NE",
"32000": "NEVADA",
"32001": "Churchill, NV",
"32003": "Clark, NV",
"32005": "Douglas, NV",
@ -1796,8 +1762,7 @@
"32029": "Storey, NV",
"32031": "Washoe, NV",
"32033": "White Pine, NV",
"32510": "Carson City, NV",
"33000": "NEW HAMPSHIRE",
"32510": "Carson, NV",
"33001": "Belknap, NH",
"33003": "Carroll, NH",
"33005": "Cheshire, NH",
@ -1808,7 +1773,6 @@
"33015": "Rockingham, NH",
"33017": "Strafford, NH",
"33019": "Sullivan, NH",
"34000": "NEW JERSEY",
"34001": "Atlantic, NJ",
"34003": "Bergen, NJ",
"34005": "Burlington, NJ",
@ -1830,7 +1794,6 @@
"34037": "Sussex, NJ",
"34039": "Union, NJ",
"34041": "Warren, NJ",
"35000": "NEW MEXICO",
"35001": "Bernalillo, NM",
"35003": "Catron, NM",
"35005": "Chaves, NM",
@ -1864,7 +1827,6 @@
"35057": "Torrance, NM",
"35059": "Union, NM",
"35061": "Valencia, NM",
"36000": "NEW YORK",
"36001": "Albany, NY",
"36003": "Allegany, NY",
"36005": "Bronx, NY",
@ -1927,7 +1889,6 @@
"36119": "Westchester, NY",
"36121": "Wyoming, NY",
"36123": "Yates, NY",
"37000": "NORTH CAROLINA",
"37001": "Alamance, NC",
"37003": "Alexander, NC",
"37005": "Alleghany, NC",
@ -2028,7 +1989,6 @@
"37195": "Wilson, NC",
"37197": "Yadkin, NC",
"37199": "Yancey, NC",
"38000": "NORTH DAKOTA",
"38001": "Adams, ND",
"38003": "Barnes, ND",
"38005": "Benson, ND",
@ -2051,7 +2011,7 @@
"38039": "Griggs, ND",
"38041": "Hettinger, ND",
"38043": "Kidder, ND",
"38045": "La Moure, ND",
"38045": "LaMoure, ND",
"38047": "Logan, ND",
"38049": "McHenry, ND",
"38051": "McIntosh, ND",
@ -2082,7 +2042,6 @@
"38101": "Ward, ND",
"38103": "Wells, ND",
"38105": "Williams, ND",
"39000": "OHIO",
"39001": "Adams, OH",
"39003": "Allen, OH",
"39005": "Ashland, OH",
@ -2171,7 +2130,6 @@
"39171": "Williams, OH",
"39173": "Wood, OH",
"39175": "Wyandot, OH",
"40000": "OKLAHOMA",
"40001": "Adair, OK",
"40003": "Alfalfa, OK",
"40005": "Atoka, OK",
@ -2249,7 +2207,6 @@
"40149": "Washita, OK",
"40151": "Woods, OK",
"40153": "Woodward, OK",
"41000": "OREGON",
"41001": "Baker, OR",
"41003": "Benton, OR",
"41005": "Clackamas, OR",
@ -2286,7 +2243,6 @@
"41067": "Washington, OR",
"41069": "Wheeler, OR",
"41071": "Yamhill, OR",
"42000": "PENNSYLVANIA",
"42001": "Adams, PA",
"42003": "Allegheny, PA",
"42005": "Armstrong, PA",
@ -2354,13 +2310,11 @@
"42129": "Westmoreland, PA",
"42131": "Wyoming, PA",
"42133": "York, PA",
"44000": "RHODE ISLAND",
"44001": "Bristol, RI",
"44003": "Kent, RI",
"44005": "Newport, RI",
"44007": "Providence, RI",
"44009": "Washington, RI",
"45000": "SOUTH CAROLINA",
"45001": "Abbeville, SC",
"45003": "Aiken, SC",
"45005": "Allendale, SC",
@ -2407,7 +2361,6 @@
"45087": "Union, SC",
"45089": "Williamsburg, SC",
"45091": "York, SC",
"46000": "SOUTH DAKOTA",
"46003": "Aurora, SD",
"46005": "Beadle, SD",
"46007": "Bennett, SD",
@ -2458,7 +2411,6 @@
"46097": "Miner, SD",
"46099": "Minnehaha, SD",
"46101": "Moody, SD",
"46102": "Oglala Lakota, SD",
"46103": "Pennington, SD",
"46105": "Perkins, SD",
"46107": "Potter, SD",
@ -2475,7 +2427,6 @@
"46129": "Walworth, SD",
"46135": "Yankton, SD",
"46137": "Ziebach, SD",
"47000": "TENNESSEE",
"47001": "Anderson, TN",
"47003": "Bedford, TN",
"47005": "Benton, TN",
@ -2571,7 +2522,6 @@
"47185": "White, TN",
"47187": "Williamson, TN",
"47189": "Wilson, TN",
"48000": "TEXAS",
"48001": "Anderson, TX",
"48003": "Andrews, TX",
"48005": "Angelina, TX",
@ -2633,7 +2583,7 @@
"48117": "Deaf Smith, TX",
"48119": "Delta, TX",
"48121": "Denton, TX",
"48123": "De Witt, TX",
"48123": "DeWitt, TX",
"48125": "Dickens, TX",
"48127": "Dimmit, TX",
"48129": "Donley, TX",
@ -2826,7 +2776,6 @@
"48503": "Young, TX",
"48505": "Zapata, TX",
"48507": "Zavala, TX",
"49000": "UTAH",
"49001": "Beaver, UT",
"49003": "Box Elder, UT",
"49005": "Cache, UT",
@ -2856,7 +2805,6 @@
"49053": "Washington, UT",
"49055": "Wayne, UT",
"49057": "Weber, UT",
"50000": "VERMONT",
"50001": "Addison, VT",
"50003": "Bennington, VT",
"50005": "Caledonia, VT",
@ -2871,7 +2819,6 @@
"50023": "Washington, VT",
"50025": "Windham, VT",
"50027": "Windsor, VT",
"51000": "VIRGINIA",
"51001": "Accomack, VA",
"51003": "Albemarle, VA",
"51005": "Alleghany, VA",
@ -2973,7 +2920,6 @@
"51530": "Buena Vista, VA",
"51540": "Charlottesville, VA",
"51550": "Chesapeake, VA",
"51560": "Clifton Forge, VA",
"51570": "Colonial Heights, VA",
"51580": "Covington, VA",
"51590": "Danville, VA",
@ -3001,14 +2947,12 @@
"51760": "Richmond, VA",
"51770": "Roanoke, VA",
"51775": "Salem, VA",
"51780": "South Boston, VA",
"51790": "Staunton, VA",
"51800": "Suffolk, VA",
"51810": "Virginia Beach, VA",
"51820": "Waynesboro, VA",
"51830": "Williamsburg, VA",
"51840": "Winchester, VA",
"53000": "WASHINGTON",
"53001": "Adams, WA",
"53003": "Asotin, WA",
"53005": "Benton, WA",
@ -3048,7 +2992,6 @@
"53073": "Whatcom, WA",
"53075": "Whitman, WA",
"53077": "Yakima, WA",
"54000": "WEST VIRGINIA",
"54001": "Barbour, WV",
"54003": "Berkeley, WV",
"54005": "Boone, WV",
@ -3104,7 +3047,6 @@
"54105": "Wirt, WV",
"54107": "Wood, WV",
"54109": "Wyoming, WV",
"55000": "WISCONSIN",
"55001": "Adams, WI",
"55003": "Ashland, WI",
"55005": "Barron, WI",
@ -3177,7 +3119,6 @@
"55137": "Waushara, WI",
"55139": "Winnebago, WI",
"55141": "Wood, WI",
"56000": "WYOMING",
"56001": "Albany, WY",
"56003": "Big Horn, WY",
"56005": "Campbell, WY",
@ -3201,20 +3142,16 @@
"56041": "Uinta, WY",
"56043": "Washakie, WY",
"56045": "Weston, WY",
"60000": "AMERICAN SAMOA",
"60010": "Eastern District, AS",
"60020": "Manu'a District, AS",
"60030": "Rose Island, AS",
"60040": "Swains Island, AS",
"60050": "Western District, AS",
"66000": "GUAM",
"66010": "Guam, GU",
"69000": "COMMONWEALTH OF THE NORTHERN MARIANA ISLANDS",
"69085": "Northern Islands, MP",
"69100": "Rota, MP",
"69110": "Saipan, MP",
"69120": "Tinian, MP",
"72000": "PUERTO RICO",
"72001": "Adjuntas, PR",
"72003": "Aguada, PR",
"72005": "Aguadilla, PR",
@ -3293,7 +3230,7 @@
"72149": "Villalba, PR",
"72151": "Yabucoa, PR",
"72153": "Yauco, PR",
"78000": "VIRGIN ISLANDS",
"74300": "Midway Islands, UM",
"78010": "St. Croix, VI",
"78020": "St. John, VI",
"78030": "St. Thomas, VI"