import os
import pandas as pd
import numpy as np
import seaborn as sns
import matplotlib.pyplot as plt
from IPython.core.display import display, HTML
%matplotlib inline
from zipfile import ZipFile
import geopandas as gpd
from shapely.geometry import Point
pd.options.display.max_columns = None
display(HTML("<style>.container { width:100% !important; }</style>"))
ZIP_SHP_PATH = os.path.join('zip://', 'data', 'Boundaries - Census Tracts - 2010.zip')
coord_system = {'init': 'epsg:4326'}
chicago_census_tracts = gpd.read_file(ZIP_SHP_PATH).to_crs(coord_system)
chicago_census_tracts.plot(figsize=(15,10))
<matplotlib.axes._subplots.AxesSubplot at 0x1e21e28b128>
chicago_census_tracts.head()
statefp10 | countyfp10 | tractce10 | namelsad10 | commarea | geoid10 | commarea_n | name10 | notes | geometry | |
---|---|---|---|---|---|---|---|---|---|---|
0 | 17 | 031 | 842400 | Census Tract 8424 | 44 | 17031842400 | 44.0 | 8424 | None | POLYGON ((-87.62404799998049 41.73021699998396... |
1 | 17 | 031 | 840300 | Census Tract 8403 | 59 | 17031840300 | 59.0 | 8403 | None | POLYGON ((-87.6860799999848 41.82295600001154,... |
2 | 17 | 031 | 841100 | Census Tract 8411 | 34 | 17031841100 | 34.0 | 8411 | None | POLYGON ((-87.62934700001183 41.8527970000265,... |
3 | 17 | 031 | 841200 | Census Tract 8412 | 31 | 17031841200 | 31.0 | 8412 | None | POLYGON ((-87.68813499997718 41.85569099999095... |
4 | 17 | 031 | 838200 | Census Tract 8382 | 28 | 17031838200 | 28.0 | 8382 | None | POLYGON ((-87.66781999997529 41.8741839999791,... |
ZIP_PATH = os.path.join('data', 'ACS_15_5YR_DP05.zip')
with ZipFile(ZIP_PATH) as zip_file:
with zip_file.open('ACS_15_5YR_DP05_with_ann.csv') as my_zipped_csv:
il_acs_15 = pd.read_csv(my_zipped_csv, header=1)
il_acs_15.head()
Id | Id2 | Geography | Estimate; SEX AND AGE - Total population | Margin of Error; SEX AND AGE - Total population | Percent; SEX AND AGE - Total population | Percent Margin of Error; SEX AND AGE - Total population | Estimate; SEX AND AGE - Total population - Male | Margin of Error; SEX AND AGE - Total population - Male | Percent; SEX AND AGE - Total population - Male | Percent Margin of Error; SEX AND AGE - Total population - Male | Estimate; SEX AND AGE - Total population - Female | Margin of Error; SEX AND AGE - Total population - Female | Percent; SEX AND AGE - Total population - Female | Percent Margin of Error; SEX AND AGE - Total population - Female | Estimate; SEX AND AGE - Under 5 years | Margin of Error; SEX AND AGE - Under 5 years | Percent; SEX AND AGE - Under 5 years | Percent Margin of Error; SEX AND AGE - Under 5 years | Estimate; SEX AND AGE - 5 to 9 years | Margin of Error; SEX AND AGE - 5 to 9 years | Percent; SEX AND AGE - 5 to 9 years | Percent Margin of Error; SEX AND AGE - 5 to 9 years | Estimate; SEX AND AGE - 10 to 14 years | Margin of Error; SEX AND AGE - 10 to 14 years | Percent; SEX AND AGE - 10 to 14 years | Percent Margin of Error; SEX AND AGE - 10 to 14 years | Estimate; SEX AND AGE - 15 to 19 years | Margin of Error; SEX AND AGE - 15 to 19 years | Percent; SEX AND AGE - 15 to 19 years | Percent Margin of Error; SEX AND AGE - 15 to 19 years | Estimate; SEX AND AGE - 20 to 24 years | Margin of Error; SEX AND AGE - 20 to 24 years | Percent; SEX AND AGE - 20 to 24 years | Percent Margin of Error; SEX AND AGE - 20 to 24 years | Estimate; SEX AND AGE - 25 to 34 years | Margin of Error; SEX AND AGE - 25 to 34 years | Percent; SEX AND AGE - 25 to 34 years | Percent Margin of Error; SEX AND AGE - 25 to 34 years | Estimate; SEX AND AGE - 35 to 44 years | Margin of Error; SEX AND AGE - 35 to 44 years | Percent; SEX AND AGE - 35 to 44 years | Percent Margin of Error; SEX AND AGE - 35 to 44 years | Estimate; SEX AND AGE - 45 to 54 years | Margin of Error; SEX AND AGE - 45 to 54 years | Percent; SEX AND AGE - 45 to 54 years | Percent Margin of Error; SEX AND AGE - 45 to 54 years | Estimate; SEX AND AGE - 55 to 59 years | Margin of Error; SEX AND AGE - 55 to 59 years | Percent; SEX AND AGE - 55 to 59 years | Percent Margin of Error; SEX AND AGE - 55 to 59 years | Estimate; SEX AND AGE - 60 to 64 years | Margin of Error; SEX AND AGE - 60 to 64 years | Percent; SEX AND AGE - 60 to 64 years | Percent Margin of Error; SEX AND AGE - 60 to 64 years | Estimate; SEX AND AGE - 65 to 74 years | Margin of Error; SEX AND AGE - 65 to 74 years | Percent; SEX AND AGE - 65 to 74 years | Percent Margin of Error; SEX AND AGE - 65 to 74 years | Estimate; SEX AND AGE - 75 to 84 years | Margin of Error; SEX AND AGE - 75 to 84 years | Percent; SEX AND AGE - 75 to 84 years | Percent Margin of Error; SEX AND AGE - 75 to 84 years | Estimate; SEX AND AGE - 85 years and over | Margin of Error; SEX AND AGE - 85 years and over | Percent; SEX AND AGE - 85 years and over | Percent Margin of Error; SEX AND AGE - 85 years and over | Estimate; SEX AND AGE - Median age (years) | Margin of Error; SEX AND AGE - Median age (years) | Percent; SEX AND AGE - Median age (years) | Percent Margin of Error; SEX AND AGE - Median age (years) | Estimate; SEX AND AGE - 18 years and over | Margin of Error; SEX AND AGE - 18 years and over | Percent; SEX AND AGE - 18 years and over | Percent Margin of Error; SEX AND AGE - 18 years and over | Estimate; SEX AND AGE - 21 years and over | Margin of Error; SEX AND AGE - 21 years and over | Percent; SEX AND AGE - 21 years and over | Percent Margin of Error; SEX AND AGE - 21 years and over | Estimate; SEX AND AGE - 62 years and over | Margin of Error; SEX AND AGE - 62 years and over | Percent; SEX AND AGE - 62 years and over | Percent Margin of Error; SEX AND AGE - 62 years and over | Estimate; SEX AND AGE - 65 years and over | Margin of Error; SEX AND AGE - 65 years and over | Percent; SEX AND AGE - 65 years and over | Percent Margin of Error; SEX AND AGE - 65 years and over | Estimate; SEX AND AGE - 18 years and over.1 | Margin of Error; SEX AND AGE - 18 years and over.1 | Percent; SEX AND AGE - 18 years and over.1 | Percent Margin of Error; SEX AND AGE - 18 years and over.1 | Estimate; SEX AND AGE - 18 years and over - Male | Margin of Error; SEX AND AGE - 18 years and over - Male | Percent; SEX AND AGE - 18 years and over - Male | Percent Margin of Error; SEX AND AGE - 18 years and over - Male | Estimate; SEX AND AGE - 18 years and over - Female | Margin of Error; SEX AND AGE - 18 years and over - Female | Percent; SEX AND AGE - 18 years and over - Female | Percent Margin of Error; SEX AND AGE - 18 years and over - Female | Estimate; SEX AND AGE - 65 years and over.1 | Margin of Error; SEX AND AGE - 65 years and over.1 | Percent; SEX AND AGE - 65 years and over.1 | Percent Margin of Error; SEX AND AGE - 65 years and over.1 | Estimate; SEX AND AGE - 65 years and over - Male | Margin of Error; SEX AND AGE - 65 years and over - Male | Percent; SEX AND AGE - 65 years and over - Male | Percent Margin of Error; SEX AND AGE - 65 years and over - Male | Estimate; SEX AND AGE - 65 years and over - Female | Margin of Error; SEX AND AGE - 65 years and over - Female | Percent; SEX AND AGE - 65 years and over - Female | Percent Margin of Error; SEX AND AGE - 65 years and over - Female | Estimate; RACE - Total population | Margin of Error; RACE - Total population | Percent; RACE - Total population | Percent Margin of Error; RACE - Total population | Estimate; RACE - Total population - One race | Margin of Error; RACE - Total population - One race | Percent; RACE - Total population - One race | Percent Margin of Error; RACE - Total population - One race | Estimate; RACE - Total population - Two or more races | Margin of Error; RACE - Total population - Two or more races | Percent; RACE - Total population - Two or more races | Percent Margin of Error; RACE - Total population - Two or more races | Estimate; RACE - One race | Margin of Error; RACE - One race | Percent; RACE - One race | Percent Margin of Error; RACE - One race | Estimate; RACE - One race - White | Margin of Error; RACE - One race - White | Percent; RACE - One race - White | Percent Margin of Error; RACE - One race - White | Estimate; RACE - One race - Black or African American | Margin of Error; RACE - One race - Black or African American | Percent; RACE - One race - Black or African American | Percent Margin of Error; RACE - One race - Black or African American | Estimate; RACE - One race - American Indian and Alaska Native | Margin of Error; RACE - One race - American Indian and Alaska Native | Percent; RACE - One race - American Indian and Alaska Native | Percent Margin of Error; RACE - One race - American Indian and Alaska Native | Estimate; RACE - One race - American Indian and Alaska Native - Cherokee tribal grouping | Margin of Error; RACE - One race - American Indian and Alaska Native - Cherokee tribal grouping | Percent; RACE - One race - American Indian and Alaska Native - Cherokee tribal grouping | Percent Margin of Error; RACE - One race - American Indian and Alaska Native - Cherokee tribal grouping | Estimate; RACE - One race - American Indian and Alaska Native - Chippewa tribal grouping | Margin of Error; RACE - One race - American Indian and Alaska Native - Chippewa tribal grouping | Percent; RACE - One race - American Indian and Alaska Native - Chippewa tribal grouping | Percent Margin of Error; RACE - One race - American Indian and Alaska Native - Chippewa tribal grouping | Estimate; RACE - One race - American Indian and Alaska Native - Navajo tribal grouping | Margin of Error; RACE - One race - American Indian and Alaska Native - Navajo tribal grouping | Percent; RACE - One race - American Indian and Alaska Native - Navajo tribal grouping | Percent Margin of Error; RACE - One race - American Indian and Alaska Native - Navajo tribal grouping | Estimate; RACE - One race - American Indian and Alaska Native - Sioux tribal grouping | Margin of Error; RACE - One race - American Indian and Alaska Native - Sioux tribal grouping | Percent; RACE - One race - American Indian and Alaska Native - Sioux tribal grouping | Percent Margin of Error; RACE - One race - American Indian and Alaska Native - Sioux tribal grouping | Estimate; RACE - One race - Asian | Margin of Error; RACE - One race - Asian | Percent; RACE - One race - Asian | Percent Margin of Error; RACE - One race - Asian | Estimate; RACE - One race - Asian - Asian Indian | Margin of Error; RACE - One race - Asian - Asian Indian | Percent; RACE - One race - Asian - Asian Indian | Percent Margin of Error; RACE - One race - Asian - Asian Indian | Estimate; RACE - One race - Asian - Chinese | Margin of Error; RACE - One race - Asian - Chinese | Percent; RACE - One race - Asian - Chinese | Percent Margin of Error; RACE - One race - Asian - Chinese | Estimate; RACE - One race - Asian - Filipino | Margin of Error; RACE - One race - Asian - Filipino | Percent; RACE - One race - Asian - Filipino | Percent Margin of Error; RACE - One race - Asian - Filipino | Estimate; RACE - One race - Asian - Japanese | Margin of Error; RACE - One race - Asian - Japanese | Percent; RACE - One race - Asian - Japanese | Percent Margin of Error; RACE - One race - Asian - Japanese | Estimate; RACE - One race - Asian - Korean | Margin of Error; RACE - One race - Asian - Korean | Percent; RACE - One race - Asian - Korean | Percent Margin of Error; RACE - One race - Asian - Korean | Estimate; RACE - One race - Asian - Vietnamese | Margin of Error; RACE - One race - Asian - Vietnamese | Percent; RACE - One race - Asian - Vietnamese | Percent Margin of Error; RACE - One race - Asian - Vietnamese | Estimate; RACE - One race - Asian - Other Asian | Margin of Error; RACE - One race - Asian - Other Asian | Percent; RACE - One race - Asian - Other Asian | Percent Margin of Error; RACE - One race - Asian - Other Asian | Estimate; RACE - One race - Native Hawaiian and Other Pacific Islander | Margin of Error; RACE - One race - Native Hawaiian and Other Pacific Islander | Percent; RACE - One race - Native Hawaiian and Other Pacific Islander | Percent Margin of Error; RACE - One race - Native Hawaiian and Other Pacific Islander | Estimate; RACE - One race - Native Hawaiian and Other Pacific Islander - Native Hawaiian | Margin of Error; RACE - One race - Native Hawaiian and Other Pacific Islander - Native Hawaiian | Percent; RACE - One race - Native Hawaiian and Other Pacific Islander - Native Hawaiian | Percent Margin of Error; RACE - One race - Native Hawaiian and Other Pacific Islander - Native Hawaiian | Estimate; RACE - One race - Native Hawaiian and Other Pacific Islander - Guamanian or Chamorro | Margin of Error; RACE - One race - Native Hawaiian and Other Pacific Islander - Guamanian or Chamorro | Percent; RACE - One race - Native Hawaiian and Other Pacific Islander - Guamanian or Chamorro | Percent Margin of Error; RACE - One race - Native Hawaiian and Other Pacific Islander - Guamanian or Chamorro | Estimate; RACE - One race - Native Hawaiian and Other Pacific Islander - Samoan | Margin of Error; RACE - One race - Native Hawaiian and Other Pacific Islander - Samoan | Percent; RACE - One race - Native Hawaiian and Other Pacific Islander - Samoan | Percent Margin of Error; RACE - One race - Native Hawaiian and Other Pacific Islander - Samoan | Estimate; RACE - One race - Native Hawaiian and Other Pacific Islander - Other Pacific Islander | Margin of Error; RACE - One race - Native Hawaiian and Other Pacific Islander - Other Pacific Islander | Percent; RACE - One race - Native Hawaiian and Other Pacific Islander - Other Pacific Islander | Percent Margin of Error; RACE - One race - Native Hawaiian and Other Pacific Islander - Other Pacific Islander | Estimate; RACE - One race - Some other race | Margin of Error; RACE - One race - Some other race | Percent; RACE - One race - Some other race | Percent Margin of Error; RACE - One race - Some other race | Estimate; RACE - Two or more races | Margin of Error; RACE - Two or more races | Percent; RACE - Two or more races | Percent Margin of Error; RACE - Two or more races | Estimate; RACE - Two or more races - White and Black or African American | Margin of Error; RACE - Two or more races - White and Black or African American | Percent; RACE - Two or more races - White and Black or African American | Percent Margin of Error; RACE - Two or more races - White and Black or African American | Estimate; RACE - Two or more races - White and American Indian and Alaska Native | Margin of Error; RACE - Two or more races - White and American Indian and Alaska Native | Percent; RACE - Two or more races - White and American Indian and Alaska Native | Percent Margin of Error; RACE - Two or more races - White and American Indian and Alaska Native | Estimate; RACE - Two or more races - White and Asian | Margin of Error; RACE - Two or more races - White and Asian | Percent; RACE - Two or more races - White and Asian | Percent Margin of Error; RACE - Two or more races - White and Asian | Estimate; RACE - Two or more races - Black or African American and American Indian and Alaska Native | Margin of Error; RACE - Two or more races - Black or African American and American Indian and Alaska Native | Percent; RACE - Two or more races - Black or African American and American Indian and Alaska Native | Percent Margin of Error; RACE - Two or more races - Black or African American and American Indian and Alaska Native | Estimate; RACE - Race alone or in combination with one or more other races - Total population | Margin of Error; RACE - Race alone or in combination with one or more other races - Total population | Percent; RACE - Race alone or in combination with one or more other races - Total population | Percent Margin of Error; RACE - Race alone or in combination with one or more other races - Total population | Estimate; RACE - Race alone or in combination with one or more other races - Total population - White | Margin of Error; RACE - Race alone or in combination with one or more other races - Total population - White | Percent; RACE - Race alone or in combination with one or more other races - Total population - White | Percent Margin of Error; RACE - Race alone or in combination with one or more other races - Total population - White | Estimate; RACE - Race alone or in combination with one or more other races - Total population - Black or African American | Margin of Error; RACE - Race alone or in combination with one or more other races - Total population - Black or African American | Percent; RACE - Race alone or in combination with one or more other races - Total population - Black or African American | Percent Margin of Error; RACE - Race alone or in combination with one or more other races - Total population - Black or African American | Estimate; RACE - Race alone or in combination with one or more other races - Total population - American Indian and Alaska Native | Margin of Error; RACE - Race alone or in combination with one or more other races - Total population - American Indian and Alaska Native | Percent; RACE - Race alone or in combination with one or more other races - Total population - American Indian and Alaska Native | Percent Margin of Error; RACE - Race alone or in combination with one or more other races - Total population - American Indian and Alaska Native | Estimate; RACE - Race alone or in combination with one or more other races - Total population - Asian | Margin of Error; RACE - Race alone or in combination with one or more other races - Total population - Asian | Percent; RACE - Race alone or in combination with one or more other races - Total population - Asian | Percent Margin of Error; RACE - Race alone or in combination with one or more other races - Total population - Asian | Estimate; RACE - Race alone or in combination with one or more other races - Total population - Native Hawaiian and Other Pacific Islander | Margin of Error; RACE - Race alone or in combination with one or more other races - Total population - Native Hawaiian and Other Pacific Islander | Percent; RACE - Race alone or in combination with one or more other races - Total population - Native Hawaiian and Other Pacific Islander | Percent Margin of Error; RACE - Race alone or in combination with one or more other races - Total population - Native Hawaiian and Other Pacific Islander | Estimate; RACE - Race alone or in combination with one or more other races - Total population - Some other race | Margin of Error; RACE - Race alone or in combination with one or more other races - Total population - Some other race | Percent; RACE - Race alone or in combination with one or more other races - Total population - Some other race | Percent Margin of Error; RACE - Race alone or in combination with one or more other races - Total population - Some other race | Estimate; HISPANIC OR LATINO AND RACE - Total population | Margin of Error; HISPANIC OR LATINO AND RACE - Total population | Percent; HISPANIC OR LATINO AND RACE - Total population | Percent Margin of Error; HISPANIC OR LATINO AND RACE - Total population | Estimate; HISPANIC OR LATINO AND RACE - Total population - Hispanic or Latino (of any race) | Margin of Error; HISPANIC OR LATINO AND RACE - Total population - Hispanic or Latino (of any race) | Percent; HISPANIC OR LATINO AND RACE - Total population - Hispanic or Latino (of any race) | Percent Margin of Error; HISPANIC OR LATINO AND RACE - Total population - Hispanic or Latino (of any race) | Estimate; HISPANIC OR LATINO AND RACE - Total population - Hispanic or Latino (of any race) - Mexican | Margin of Error; HISPANIC OR LATINO AND RACE - Total population - Hispanic or Latino (of any race) - Mexican | Percent; HISPANIC OR LATINO AND RACE - Total population - Hispanic or Latino (of any race) - Mexican | Percent Margin of Error; HISPANIC OR LATINO AND RACE - Total population - Hispanic or Latino (of any race) - Mexican | Estimate; HISPANIC OR LATINO AND RACE - Total population - Hispanic or Latino (of any race) - Puerto Rican | Margin of Error; HISPANIC OR LATINO AND RACE - Total population - Hispanic or Latino (of any race) - Puerto Rican | Percent; HISPANIC OR LATINO AND RACE - Total population - Hispanic or Latino (of any race) - Puerto Rican | Percent Margin of Error; HISPANIC OR LATINO AND RACE - Total population - Hispanic or Latino (of any race) - Puerto Rican | Estimate; HISPANIC OR LATINO AND RACE - Total population - Hispanic or Latino (of any race) - Cuban | Margin of Error; HISPANIC OR LATINO AND RACE - Total population - Hispanic or Latino (of any race) - Cuban | Percent; HISPANIC OR LATINO AND RACE - Total population - Hispanic or Latino (of any race) - Cuban | Percent Margin of Error; HISPANIC OR LATINO AND RACE - Total population - Hispanic or Latino (of any race) - Cuban | Estimate; HISPANIC OR LATINO AND RACE - Total population - Hispanic or Latino (of any race) - Other Hispanic or Latino | Margin of Error; HISPANIC OR LATINO AND RACE - Total population - Hispanic or Latino (of any race) - Other Hispanic or Latino | Percent; HISPANIC OR LATINO AND RACE - Total population - Hispanic or Latino (of any race) - Other Hispanic or Latino | Percent Margin of Error; HISPANIC OR LATINO AND RACE - Total population - Hispanic or Latino (of any race) - Other Hispanic or Latino | Estimate; HISPANIC OR LATINO AND RACE - Total population - Not Hispanic or Latino | Margin of Error; HISPANIC OR LATINO AND RACE - Total population - Not Hispanic or Latino | Percent; HISPANIC OR LATINO AND RACE - Total population - Not Hispanic or Latino | Percent Margin of Error; HISPANIC OR LATINO AND RACE - Total population - Not Hispanic or Latino | Estimate; HISPANIC OR LATINO AND RACE - Total population - Not Hispanic or Latino - White alone | Margin of Error; HISPANIC OR LATINO AND RACE - Total population - Not Hispanic or Latino - White alone | Percent; HISPANIC OR LATINO AND RACE - Total population - Not Hispanic or Latino - White alone | Percent Margin of Error; HISPANIC OR LATINO AND RACE - Total population - Not Hispanic or Latino - White alone | Estimate; HISPANIC OR LATINO AND RACE - Total population - Not Hispanic or Latino - Black or African American alone | Margin of Error; HISPANIC OR LATINO AND RACE - Total population - Not Hispanic or Latino - Black or African American alone | Percent; HISPANIC OR LATINO AND RACE - Total population - Not Hispanic or Latino - Black or African American alone | Percent Margin of Error; HISPANIC OR LATINO AND RACE - Total population - Not Hispanic or Latino - Black or African American alone | Estimate; HISPANIC OR LATINO AND RACE - Total population - Not Hispanic or Latino - American Indian and Alaska Native alone | Margin of Error; HISPANIC OR LATINO AND RACE - Total population - Not Hispanic or Latino - American Indian and Alaska Native alone | Percent; HISPANIC OR LATINO AND RACE - Total population - Not Hispanic or Latino - American Indian and Alaska Native alone | Percent Margin of Error; HISPANIC OR LATINO AND RACE - Total population - Not Hispanic or Latino - American Indian and Alaska Native alone | Estimate; HISPANIC OR LATINO AND RACE - Total population - Not Hispanic or Latino - Asian alone | Margin of Error; HISPANIC OR LATINO AND RACE - Total population - Not Hispanic or Latino - Asian alone | Percent; HISPANIC OR LATINO AND RACE - Total population - Not Hispanic or Latino - Asian alone | Percent Margin of Error; HISPANIC OR LATINO AND RACE - Total population - Not Hispanic or Latino - Asian alone | Estimate; HISPANIC OR LATINO AND RACE - Total population - Not Hispanic or Latino - Native Hawaiian and Other Pacific Islander alone | Margin of Error; HISPANIC OR LATINO AND RACE - Total population - Not Hispanic or Latino - Native Hawaiian and Other Pacific Islander alone | Percent; HISPANIC OR LATINO AND RACE - Total population - Not Hispanic or Latino - Native Hawaiian and Other Pacific Islander alone | Percent Margin of Error; HISPANIC OR LATINO AND RACE - Total population - Not Hispanic or Latino - Native Hawaiian and Other Pacific Islander alone | Estimate; HISPANIC OR LATINO AND RACE - Total population - Not Hispanic or Latino - Some other race alone | Margin of Error; HISPANIC OR LATINO AND RACE - Total population - Not Hispanic or Latino - Some other race alone | Percent; HISPANIC OR LATINO AND RACE - Total population - Not Hispanic or Latino - Some other race alone | Percent Margin of Error; HISPANIC OR LATINO AND RACE - Total population - Not Hispanic or Latino - Some other race alone | Estimate; HISPANIC OR LATINO AND RACE - Total population - Not Hispanic or Latino - Two or more races | Margin of Error; HISPANIC OR LATINO AND RACE - Total population - Not Hispanic or Latino - Two or more races | Percent; HISPANIC OR LATINO AND RACE - Total population - Not Hispanic or Latino - Two or more races | Percent Margin of Error; HISPANIC OR LATINO AND RACE - Total population - Not Hispanic or Latino - Two or more races | Estimate; HISPANIC OR LATINO AND RACE - Total population - Not Hispanic or Latino - Two or more races - Two races including Some other race | Margin of Error; HISPANIC OR LATINO AND RACE - Total population - Not Hispanic or Latino - Two or more races - Two races including Some other race | Percent; HISPANIC OR LATINO AND RACE - Total population - Not Hispanic or Latino - Two or more races - Two races including Some other race | Percent Margin of Error; HISPANIC OR LATINO AND RACE - Total population - Not Hispanic or Latino - Two or more races - Two races including Some other race | Estimate; HISPANIC OR LATINO AND RACE - Total population - Not Hispanic or Latino - Two or more races - Two races excluding Some other race, and Three or more races | Margin of Error; HISPANIC OR LATINO AND RACE - Total population - Not Hispanic or Latino - Two or more races - Two races excluding Some other race, and Three or more races | Percent; HISPANIC OR LATINO AND RACE - Total population - Not Hispanic or Latino - Two or more races - Two races excluding Some other race, and Three or more races | Percent Margin of Error; HISPANIC OR LATINO AND RACE - Total population - Not Hispanic or Latino - Two or more races - Two races excluding Some other race, and Three or more races | Estimate; HISPANIC OR LATINO AND RACE - Total housing units | Margin of Error; HISPANIC OR LATINO AND RACE - Total housing units | Percent; HISPANIC OR LATINO AND RACE - Total housing units | Percent Margin of Error; HISPANIC OR LATINO AND RACE - Total housing units | Estimate; CITIZEN, VOTING AGE POPULATION - Citizen, 18 and over population | Margin of Error; CITIZEN, VOTING AGE POPULATION - Citizen, 18 and over population | Percent; CITIZEN, VOTING AGE POPULATION - Citizen, 18 and over population | Percent Margin of Error; CITIZEN, VOTING AGE POPULATION - Citizen, 18 and over population | Estimate; CITIZEN, VOTING AGE POPULATION - Citizen, 18 and over population - Male | Margin of Error; CITIZEN, VOTING AGE POPULATION - Citizen, 18 and over population - Male | Percent; CITIZEN, VOTING AGE POPULATION - Citizen, 18 and over population - Male | Percent Margin of Error; CITIZEN, VOTING AGE POPULATION - Citizen, 18 and over population - Male | Estimate; CITIZEN, VOTING AGE POPULATION - Citizen, 18 and over population - Female | Margin of Error; CITIZEN, VOTING AGE POPULATION - Citizen, 18 and over population - Female | Percent; CITIZEN, VOTING AGE POPULATION - Citizen, 18 and over population - Female | Percent Margin of Error; CITIZEN, VOTING AGE POPULATION - Citizen, 18 and over population - Female | |
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
0 | 1400000US17031010100 | 17031010100 | Census Tract 101, Cook County, Illinois | 4106 | 468 | 4106 | (X) | 1891 | 267 | 46.1 | 4.7 | 2215 | 338 | 53.9 | 4.7 | 268 | 89 | 6.5 | 2.1 | 159 | 93 | 3.9 | 2.1 | 207 | 137 | 5.0 | 3.2 | 229 | 146 | 5.6 | 3.2 | 249 | 127 | 6.1 | 3.0 | 736 | 264 | 17.9 | 5.9 | 881 | 215 | 21.5 | 5.2 | 543 | 170 | 13.2 | 4.1 | 436 | 167 | 10.6 | 4.1 | 227 | 105 | 5.5 | 2.4 | 164 | 84 | 4.0 | 2.1 | 7 | 16 | 0.2 | 0.4 | 0 | 11 | 0.0 | 0.7 | 36.6 | 2.2 | (X) | (X) | 3316 | 338 | 80.8 | 5.2 | 3217 | 317 | 78.3 | 5.3 | 297 | 115 | 7.2 | 2.9 | 171 | 83 | 4.2 | 2.1 | 3316 | 338 | 3316 | (X) | 1536 | 236 | 46.3 | 5.5 | 1780 | 262 | 53.7 | 5.5 | 171 | 83 | 171 | (X) | 44 | 46 | 25.7 | 21.3 | 127 | 69 | 74.3 | 21.3 | 4106 | 468 | 4106 | (X) | 3993 | 478 | 97.2 | 2.0 | 113 | 83 | 2.8 | 2.0 | 3993 | 478 | 97.2 | 2.0 | 2186 | 414 | 53.2 | 8.2 | 1586 | 365 | 38.6 | 8.1 | 0 | 11 | 0.0 | 0.7 | 0 | 11 | 0.0 | 0.7 | 0 | 11 | 0.0 | 0.7 | 0 | 11 | 0.0 | 0.7 | 0 | 11 | 0.0 | 0.7 | 155 | 227 | 3.8 | 5.4 | 0 | 11 | 0.0 | 0.7 | 0 | 11 | 0.0 | 0.7 | 138 | 225 | 3.4 | 5.3 | 0 | 11 | 0.0 | 0.7 | 3 | 8 | 0.1 | 0.2 | 0 | 11 | 0.0 | 0.7 | 14 | 21 | 0.3 | 0.5 | 0 | 11 | 0.0 | 0.7 | 0 | 11 | 0.0 | 0.7 | 0 | 11 | 0.0 | 0.7 | 0 | 11 | 0.0 | 0.7 | 0 | 11 | 0.0 | 0.7 | 66 | 47 | 1.6 | 1.2 | 113 | 83 | 2.8 | 2.0 | 46 | 57 | 1.1 | 1.4 | 0 | 11 | 0.0 | 0.7 | 29 | 47 | 0.7 | 1.1 | 14 | 22 | 0.3 | 0.5 | 4106 | 468 | 4106 | (X) | 2271 | 422 | 55.3 | 8.5 | 1670 | 355 | 40.7 | 7.9 | 24 | 27 | 0.6 | 0.7 | 184 | 232 | 4.5 | 5.5 | 0 | 11 | 0.0 | 0.7 | 80 | 57 | 1.9 | 1.4 | 4106 | 468 | 4106 | (X) | 475 | 317 | 11.6 | 7.1 | 271 | 287 | 6.6 | 6.7 | 114 | 137 | 2.8 | 3.2 | 0 | 11 | 0.0 | 0.7 | 90 | 85 | 2.2 | 2.1 | 3631 | 421 | 88.4 | 7.1 | 1830 | 321 | 44.6 | 7.4 | 1519 | 323 | 37.0 | 7.6 | 0 | 11 | 0.0 | 0.7 | 155 | 227 | 3.8 | 5.4 | 0 | 11 | 0.0 | 0.7 | 14 | 23 | 0.3 | 0.6 | 113 | 83 | 2.8 | 2.0 | 14 | 23 | 0.3 | 0.6 | 99 | 79 | 2.4 | 2.0 | 2625 | 41 | (X) | (X) | 2989 | 340 | 2989 | (X) | 1315 | 233 | 44.0 | 5.8 | 1674 | 254 | 56.0 | 5.8 |
1 | 1400000US17031010201 | 17031010201 | Census Tract 102.01, Cook County, Illinois | 7229 | 942 | 7229 | (X) | 3554 | 564 | 49.2 | 3.6 | 3675 | 509 | 50.8 | 3.6 | 681 | 226 | 9.4 | 2.6 | 441 | 190 | 6.1 | 2.4 | 277 | 143 | 3.8 | 1.8 | 396 | 143 | 5.5 | 1.8 | 610 | 246 | 8.4 | 3.1 | 1688 | 418 | 23.4 | 4.8 | 1103 | 300 | 15.3 | 3.8 | 1018 | 252 | 14.1 | 3.5 | 281 | 142 | 3.9 | 1.8 | 351 | 165 | 4.9 | 2.4 | 190 | 123 | 2.6 | 1.7 | 156 | 110 | 2.2 | 1.6 | 37 | 43 | 0.5 | 0.6 | 31.8 | 2.6 | (X) | (X) | 5570 | 707 | 77.1 | 3.8 | 5174 | 624 | 71.6 | 4.4 | 527 | 194 | 7.3 | 2.8 | 383 | 163 | 5.3 | 2.4 | 5570 | 707 | 5570 | (X) | 2695 | 443 | 48.4 | 4.0 | 2875 | 388 | 51.6 | 4.0 | 383 | 163 | 383 | (X) | 136 | 81 | 35.5 | 13.5 | 247 | 110 | 64.5 | 13.5 | 7229 | 942 | 7229 | (X) | 6972 | 924 | 96.4 | 2.3 | 257 | 169 | 3.6 | 2.3 | 6972 | 924 | 96.4 | 2.3 | 3388 | 692 | 46.9 | 7.6 | 3295 | 721 | 45.6 | 7.8 | 26 | 42 | 0.4 | 0.6 | 0 | 15 | 0.0 | 0.4 | 0 | 15 | 0.0 | 0.4 | 0 | 15 | 0.0 | 0.4 | 0 | 15 | 0.0 | 0.4 | 223 | 178 | 3.1 | 2.4 | 112 | 155 | 1.5 | 2.1 | 11 | 19 | 0.2 | 0.3 | 88 | 85 | 1.2 | 1.2 | 12 | 19 | 0.2 | 0.3 | 0 | 15 | 0.0 | 0.4 | 0 | 15 | 0.0 | 0.4 | 0 | 15 | 0.0 | 0.4 | 0 | 15 | 0.0 | 0.4 | 0 | 15 | 0.0 | 0.4 | 0 | 15 | 0.0 | 0.4 | 0 | 15 | 0.0 | 0.4 | 0 | 15 | 0.0 | 0.4 | 40 | 38 | 0.6 | 0.5 | 257 | 169 | 3.6 | 2.3 | 51 | 62 | 0.7 | 0.8 | 86 | 140 | 1.2 | 1.9 | 62 | 70 | 0.9 | 1.0 | 11 | 18 | 0.2 | 0.3 | 7229 | 942 | 7229 | (X) | 3601 | 702 | 49.8 | 7.4 | 3390 | 724 | 46.9 | 7.8 | 123 | 146 | 1.7 | 2.0 | 285 | 193 | 3.9 | 2.6 | 11 | 18 | 0.2 | 0.3 | 76 | 77 | 1.1 | 1.1 | 7229 | 942 | 7229 | (X) | 1990 | 657 | 27.5 | 7.2 | 1744 | 633 | 24.1 | 7.2 | 53 | 64 | 0.7 | 0.9 | 104 | 120 | 1.4 | 1.7 | 89 | 72 | 1.2 | 1.0 | 5239 | 708 | 72.5 | 7.2 | 1538 | 255 | 21.3 | 4.5 | 3295 | 721 | 45.6 | 7.8 | 26 | 42 | 0.4 | 0.6 | 223 | 178 | 3.1 | 2.4 | 0 | 15 | 0.0 | 0.4 | 11 | 17 | 0.2 | 0.2 | 146 | 135 | 2.0 | 1.8 | 0 | 15 | 0.0 | 0.4 | 146 | 135 | 2.0 | 1.8 | 3007 | 66 | (X) | (X) | 3847 | 455 | 3847 | (X) | 1824 | 352 | 47.4 | 5.6 | 2023 | 261 | 52.6 | 5.6 |
2 | 1400000US17031010202 | 17031010202 | Census Tract 102.02, Cook County, Illinois | 2304 | 271 | 2304 | (X) | 1215 | 199 | 52.7 | 5.2 | 1089 | 163 | 47.3 | 5.2 | 197 | 86 | 8.6 | 3.5 | 113 | 72 | 4.9 | 3.0 | 67 | 48 | 2.9 | 2.0 | 76 | 50 | 3.3 | 2.1 | 171 | 99 | 7.4 | 3.9 | 378 | 111 | 16.4 | 4.6 | 361 | 101 | 15.7 | 4.6 | 260 | 99 | 11.3 | 4.5 | 100 | 59 | 4.3 | 2.5 | 222 | 94 | 9.6 | 3.7 | 174 | 74 | 7.6 | 2.9 | 120 | 76 | 5.2 | 3.2 | 65 | 39 | 2.8 | 1.7 | 37.8 | 4.0 | (X) | (X) | 1919 | 241 | 83.3 | 4.9 | 1836 | 227 | 79.7 | 4.8 | 483 | 190 | 21.0 | 7.2 | 359 | 129 | 15.6 | 5.1 | 1919 | 241 | 1919 | (X) | 1006 | 193 | 52.4 | 6.1 | 913 | 138 | 47.6 | 6.1 | 359 | 129 | 359 | (X) | 151 | 104 | 42.1 | 18.6 | 208 | 71 | 57.9 | 18.6 | 2304 | 271 | 2304 | (X) | 2234 | 276 | 97.0 | 2.6 | 70 | 60 | 3.0 | 2.6 | 2234 | 276 | 97.0 | 2.6 | 1178 | 234 | 51.1 | 8.8 | 674 | 166 | 29.3 | 7.9 | 12 | 17 | 0.5 | 0.7 | 0 | 11 | 0.0 | 1.2 | 0 | 11 | 0.0 | 1.2 | 0 | 11 | 0.0 | 1.2 | 0 | 11 | 0.0 | 1.2 | 185 | 184 | 8.0 | 7.5 | 105 | 169 | 4.6 | 7.1 | 16 | 22 | 0.7 | 0.9 | 18 | 22 | 0.8 | 0.9 | 0 | 11 | 0.0 | 1.2 | 0 | 11 | 0.0 | 1.2 | 0 | 11 | 0.0 | 1.2 | 46 | 70 | 2.0 | 3.0 | 0 | 11 | 0.0 | 1.2 | 0 | 11 | 0.0 | 1.2 | 0 | 11 | 0.0 | 1.2 | 0 | 11 | 0.0 | 1.2 | 0 | 11 | 0.0 | 1.2 | 185 | 132 | 8.0 | 5.5 | 70 | 60 | 3.0 | 2.6 | 2 | 9 | 0.1 | 0.4 | 27 | 42 | 1.2 | 1.8 | 5 | 9 | 0.2 | 0.4 | 0 | 11 | 0.0 | 1.2 | 2304 | 271 | 2304 | (X) | 1229 | 241 | 53.3 | 9.0 | 676 | 167 | 29.3 | 8.0 | 58 | 53 | 2.5 | 2.3 | 190 | 186 | 8.2 | 7.5 | 0 | 11 | 0.0 | 1.2 | 221 | 138 | 9.6 | 5.7 | 2304 | 271 | 2304 | (X) | 609 | 210 | 26.4 | 7.8 | 428 | 166 | 18.6 | 6.6 | 51 | 57 | 2.2 | 2.5 | 15 | 25 | 0.7 | 1.1 | 115 | 103 | 5.0 | 4.3 | 1695 | 235 | 73.6 | 7.8 | 817 | 214 | 35.5 | 9.2 | 648 | 162 | 28.1 | 7.7 | 0 | 11 | 0.0 | 1.2 | 177 | 182 | 7.7 | 7.4 | 0 | 11 | 0.0 | 1.2 | 0 | 11 | 0.0 | 1.2 | 53 | 53 | 2.3 | 2.3 | 19 | 30 | 0.8 | 1.3 | 34 | 42 | 1.5 | 1.8 | 1227 | 35 | (X) | (X) | 1499 | 201 | 1499 | (X) | 827 | 166 | 55.2 | 6.6 | 672 | 116 | 44.8 | 6.6 |
3 | 1400000US17031010300 | 17031010300 | Census Tract 103, Cook County, Illinois | 6077 | 694 | 6077 | (X) | 3095 | 457 | 50.9 | 3.9 | 2982 | 377 | 49.1 | 3.9 | 372 | 156 | 6.1 | 2.3 | 208 | 98 | 3.4 | 1.5 | 122 | 90 | 2.0 | 1.4 | 235 | 144 | 3.9 | 2.3 | 389 | 216 | 6.4 | 3.2 | 1156 | 294 | 19.0 | 4.5 | 882 | 243 | 14.5 | 3.8 | 1107 | 317 | 18.2 | 5.1 | 267 | 105 | 4.4 | 1.8 | 289 | 128 | 4.8 | 2.0 | 538 | 164 | 8.9 | 2.6 | 288 | 125 | 4.7 | 2.1 | 224 | 87 | 3.7 | 1.4 | 40.1 | 4.8 | (X) | (X) | 5259 | 585 | 86.5 | 3.7 | 5140 | 555 | 84.6 | 3.6 | 1241 | 275 | 20.4 | 4.3 | 1050 | 248 | 17.3 | 4.0 | 5259 | 585 | 5259 | (X) | 2642 | 388 | 50.2 | 4.3 | 2617 | 347 | 49.8 | 4.3 | 1050 | 248 | 1050 | (X) | 397 | 104 | 37.8 | 8.2 | 653 | 199 | 62.2 | 8.2 | 6077 | 694 | 6077 | (X) | 5910 | 697 | 97.3 | 1.7 | 167 | 99 | 2.7 | 1.7 | 5910 | 697 | 97.3 | 1.7 | 3478 | 518 | 57.2 | 8.0 | 1546 | 349 | 25.4 | 5.2 | 6 | 12 | 0.1 | 0.2 | 0 | 15 | 0.0 | 0.5 | 0 | 15 | 0.0 | 0.5 | 0 | 15 | 0.0 | 0.5 | 0 | 15 | 0.0 | 0.5 | 751 | 559 | 12.4 | 8.5 | 14 | 30 | 0.2 | 0.5 | 43 | 40 | 0.7 | 0.7 | 60 | 51 | 1.0 | 0.8 | 0 | 15 | 0.0 | 0.5 | 4 | 9 | 0.1 | 0.1 | 7 | 15 | 0.1 | 0.2 | 623 | 547 | 10.3 | 8.5 | 0 | 15 | 0.0 | 0.5 | 0 | 15 | 0.0 | 0.5 | 0 | 15 | 0.0 | 0.5 | 0 | 15 | 0.0 | 0.5 | 0 | 15 | 0.0 | 0.5 | 129 | 116 | 2.1 | 1.9 | 167 | 99 | 2.7 | 1.7 | 48 | 45 | 0.8 | 0.8 | 0 | 15 | 0.0 | 0.5 | 0 | 15 | 0.0 | 0.5 | 13 | 20 | 0.2 | 0.3 | 6077 | 694 | 6077 | (X) | 3606 | 511 | 59.3 | 7.9 | 1660 | 363 | 27.3 | 5.5 | 61 | 59 | 1.0 | 1.0 | 773 | 557 | 12.7 | 8.5 | 5 | 11 | 0.1 | 0.2 | 198 | 144 | 3.3 | 2.4 | 6077 | 694 | 6077 | (X) | 979 | 406 | 16.1 | 6.6 | 649 | 373 | 10.7 | 6.0 | 47 | 43 | 0.8 | 0.7 | 58 | 91 | 1.0 | 1.5 | 225 | 172 | 3.7 | 2.8 | 5098 | 722 | 83.9 | 6.6 | 2767 | 405 | 45.5 | 6.6 | 1476 | 343 | 24.3 | 5.2 | 6 | 12 | 0.1 | 0.2 | 751 | 559 | 12.4 | 8.5 | 0 | 15 | 0.0 | 0.5 | 0 | 15 | 0.0 | 0.5 | 98 | 67 | 1.6 | 1.1 | 0 | 15 | 0.0 | 0.5 | 98 | 67 | 1.6 | 1.1 | 3264 | 95 | (X) | (X) | 4150 | 496 | 4150 | (X) | 2069 | 351 | 49.9 | 5.1 | 2081 | 296 | 50.1 | 5.1 |
4 | 1400000US17031010400 | 17031010400 | Census Tract 104, Cook County, Illinois | 5011 | 544 | 5011 | (X) | 2067 | 279 | 41.2 | 4.7 | 2944 | 446 | 58.8 | 4.7 | 196 | 115 | 3.9 | 2.0 | 162 | 100 | 3.2 | 1.9 | 111 | 95 | 2.2 | 1.8 | 1164 | 242 | 23.2 | 4.5 | 810 | 271 | 16.2 | 5.0 | 720 | 216 | 14.4 | 4.4 | 639 | 225 | 12.8 | 3.8 | 422 | 111 | 8.4 | 2.2 | 198 | 116 | 4.0 | 2.3 | 209 | 105 | 4.2 | 2.2 | 311 | 165 | 6.2 | 3.4 | 21 | 25 | 0.4 | 0.5 | 48 | 44 | 1.0 | 0.9 | 25.4 | 2.2 | (X) | (X) | 4441 | 427 | 88.6 | 4.1 | 3086 | 339 | 61.6 | 4.8 | 531 | 185 | 10.6 | 3.9 | 380 | 166 | 7.6 | 3.4 | 4441 | 427 | 4441 | (X) | 1807 | 255 | 40.7 | 5.0 | 2634 | 369 | 59.3 | 5.0 | 380 | 166 | 380 | (X) | 154 | 105 | 40.5 | 17.3 | 226 | 103 | 59.5 | 17.3 | 5011 | 544 | 5011 | (X) | 4834 | 547 | 96.5 | 1.9 | 177 | 96 | 3.5 | 1.9 | 4834 | 547 | 96.5 | 1.9 | 3743 | 507 | 74.7 | 7.4 | 660 | 382 | 13.2 | 7.2 | 0 | 15 | 0.0 | 0.5 | 0 | 15 | 0.0 | 0.5 | 0 | 15 | 0.0 | 0.5 | 0 | 15 | 0.0 | 0.5 | 0 | 15 | 0.0 | 0.5 | 336 | 170 | 6.7 | 3.4 | 109 | 55 | 2.2 | 1.1 | 30 | 31 | 0.6 | 0.6 | 63 | 47 | 1.3 | 0.9 | 0 | 15 | 0.0 | 0.5 | 63 | 90 | 1.3 | 1.8 | 71 | 115 | 1.4 | 2.3 | 0 | 15 | 0.0 | 0.5 | 0 | 15 | 0.0 | 0.5 | 0 | 15 | 0.0 | 0.5 | 0 | 15 | 0.0 | 0.5 | 0 | 15 | 0.0 | 0.5 | 0 | 15 | 0.0 | 0.5 | 95 | 106 | 1.9 | 2.1 | 177 | 96 | 3.5 | 1.9 | 46 | 41 | 0.9 | 0.8 | 0 | 15 | 0.0 | 0.5 | 44 | 50 | 0.9 | 1.0 | 0 | 15 | 0.0 | 0.5 | 5011 | 544 | 5011 | (X) | 3865 | 513 | 77.1 | 7.4 | 719 | 385 | 14.3 | 7.2 | 27 | 31 | 0.5 | 0.6 | 421 | 190 | 8.4 | 3.8 | 14 | 22 | 0.3 | 0.5 | 155 | 120 | 3.1 | 2.4 | 5011 | 544 | 5011 | (X) | 417 | 179 | 8.3 | 3.3 | 289 | 145 | 5.8 | 2.8 | 27 | 28 | 0.5 | 0.6 | 37 | 60 | 0.7 | 1.2 | 64 | 80 | 1.3 | 1.6 | 4594 | 494 | 91.7 | 3.3 | 3467 | 479 | 69.2 | 7.5 | 613 | 361 | 12.2 | 6.8 | 0 | 15 | 0.0 | 0.5 | 328 | 170 | 6.5 | 3.4 | 0 | 15 | 0.0 | 0.5 | 36 | 57 | 0.7 | 1.1 | 150 | 89 | 3.0 | 1.8 | 47 | 53 | 0.9 | 1.1 | 103 | 68 | 2.1 | 1.3 | 2199 | 72 | (X) | (X) | 4144 | 403 | 4144 | (X) | 1642 | 204 | 39.6 | 4.9 | 2502 | 375 | 60.4 | 4.9 |
one_race_cols = []
for col_name in il_acs_15.columns.tolist():
if ("One race" in col_name) & ("Percent;" in col_name):
one_race_cols.append(col_name)
one_race_cols
['Percent; RACE - Total population - One race', 'Percent; RACE - One race', 'Percent; RACE - One race - White', 'Percent; RACE - One race - Black or African American', 'Percent; RACE - One race - American Indian and Alaska Native', 'Percent; RACE - One race - American Indian and Alaska Native - Cherokee tribal grouping', 'Percent; RACE - One race - American Indian and Alaska Native - Chippewa tribal grouping', 'Percent; RACE - One race - American Indian and Alaska Native - Navajo tribal grouping', 'Percent; RACE - One race - American Indian and Alaska Native - Sioux tribal grouping', 'Percent; RACE - One race - Asian', 'Percent; RACE - One race - Asian - Asian Indian', 'Percent; RACE - One race - Asian - Chinese', 'Percent; RACE - One race - Asian - Filipino', 'Percent; RACE - One race - Asian - Japanese', 'Percent; RACE - One race - Asian - Korean', 'Percent; RACE - One race - Asian - Vietnamese', 'Percent; RACE - One race - Asian - Other Asian', 'Percent; RACE - One race - Native Hawaiian and Other Pacific Islander', 'Percent; RACE - One race - Native Hawaiian and Other Pacific Islander - Native Hawaiian', 'Percent; RACE - One race - Native Hawaiian and Other Pacific Islander - Guamanian or Chamorro', 'Percent; RACE - One race - Native Hawaiian and Other Pacific Islander - Samoan', 'Percent; RACE - One race - Native Hawaiian and Other Pacific Islander - Other Pacific Islander', 'Percent; RACE - One race - Some other race']
race_df = il_acs_15[['Id2',
'Percent; RACE - One race',
'Percent; RACE - One race - White',
'Percent; RACE - One race - Black or African American',
'Percent; RACE - One race - Asian',
'Percent; RACE - One race - Some other race']].copy()
race_df.head()
Id2 | Percent; RACE - One race | Percent; RACE - One race - White | Percent; RACE - One race - Black or African American | Percent; RACE - One race - Asian | Percent; RACE - One race - Some other race | |
---|---|---|---|---|---|---|
0 | 17031010100 | 97.2 | 53.2 | 38.6 | 3.8 | 1.6 |
1 | 17031010201 | 96.4 | 46.9 | 45.6 | 3.1 | 0.6 |
2 | 17031010202 | 97.0 | 51.1 | 29.3 | 8.0 | 8.0 |
3 | 17031010300 | 97.3 | 57.2 | 25.4 | 12.4 | 2.1 |
4 | 17031010400 | 96.5 | 74.7 | 13.2 | 6.7 | 1.9 |
ZIP_SHP_PATH = os.path.join('zip://', 'data', 'Boundaries - Census Tracts - 2010.zip')
coord_system = {'init': 'epsg:4326'}
chicago_census_tracts = gpd.read_file(ZIP_SHP_PATH).to_crs(coord_system)
chicago_census_tracts.plot(figsize=(15,10))
<matplotlib.axes._subplots.AxesSubplot at 0x1e21eb7aef0>
chicago_census_tracts.info()
<class 'geopandas.geodataframe.GeoDataFrame'> RangeIndex: 801 entries, 0 to 800 Data columns (total 10 columns): statefp10 801 non-null object countyfp10 801 non-null object tractce10 801 non-null object namelsad10 801 non-null object commarea 801 non-null object geoid10 801 non-null object commarea_n 801 non-null float64 name10 801 non-null object notes 12 non-null object geometry 801 non-null object dtypes: float64(1), object(9) memory usage: 62.7+ KB
race_df['Id2'] = race_df['Id2'].astype(str)
chicago_race = pd.merge(left=chicago_census_tracts, right=race_df, left_on='geoid10', right_on='Id2')
chicago_race.head()
statefp10 | countyfp10 | tractce10 | namelsad10 | commarea | geoid10 | commarea_n | name10 | notes | geometry | Id2 | Percent; RACE - One race | Percent; RACE - One race - White | Percent; RACE - One race - Black or African American | Percent; RACE - One race - Asian | Percent; RACE - One race - Some other race | |
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
0 | 17 | 031 | 842400 | Census Tract 8424 | 44 | 17031842400 | 44.0 | 8424 | None | POLYGON ((-87.62404799998049 41.73021699998396... | 17031842400 | 100.0 | 0.0 | 100.0 | 0.0 | 0.0 |
1 | 17 | 031 | 840300 | Census Tract 8403 | 59 | 17031840300 | 59.0 | 8403 | None | POLYGON ((-87.6860799999848 41.82295600001154,... | 17031840300 | 95.4 | 49.4 | 3.8 | 20.1 | 18.6 |
2 | 17 | 031 | 841100 | Census Tract 8411 | 34 | 17031841100 | 34.0 | 8411 | None | POLYGON ((-87.62934700001183 41.8527970000265,... | 17031841100 | 96.3 | 3.3 | 4.5 | 88.1 | 0.4 |
3 | 17 | 031 | 841200 | Census Tract 8412 | 31 | 17031841200 | 31.0 | 8412 | None | POLYGON ((-87.68813499997718 41.85569099999095... | 17031841200 | 98.2 | 51.8 | 3.9 | 0.4 | 42.0 |
4 | 17 | 031 | 838200 | Census Tract 8382 | 28 | 17031838200 | 28.0 | 8382 | None | POLYGON ((-87.66781999997529 41.8741839999791,... | 17031838200 | 96.6 | 53.6 | 23.3 | 15.2 | 4.4 |
chicago_race[chicago_race['Percent; RACE - One race - Asian'] == '-']
statefp10 | countyfp10 | tractce10 | namelsad10 | commarea | geoid10 | commarea_n | name10 | notes | geometry | Id2 | Percent; RACE - One race | Percent; RACE - One race - White | Percent; RACE - One race - Black or African American | Percent; RACE - One race - Asian | Percent; RACE - One race - Some other race | |
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
85 | 17 | 031 | 980100 | Census Tract 9801 | 56 | 17031980100 | 56.0 | 9801 | Half in CA 64 (Midway Airport) | POLYGON ((-87.73789600001243 41.78578500000872... | 17031980100 | - | - | - | - | - |
414 | 17 | 031 | 381700 | Census Tract 3817 | 38 | 17031381700 | 38.0 | 3817 | None | POLYGON ((-87.62798399996935 41.80191199998851... | 17031381700 | - | - | - | - | - |
667 | 17 | 031 | 980000 | Census Tract 9800 | 76 | 17031980000 | 76.0 | 9800 | Partially outside City Boundary (O'Hare) | POLYGON ((-87.92062799997296 42.00453199998842... | 17031980000 | - | - | - | - | - |
ax = chicago_race.plot(color='white', edgecolor='black', figsize=(14,14))
chicago_race[chicago_race['Id2'].isin(['17031980100', '17031381700', '17031980000'])].plot(ax=ax)
<matplotlib.axes._subplots.AxesSubplot at 0x1e21eb9a908>
zero_inds = chicago_race[chicago_race['Id2'].isin(['17031980100', '17031381700', '17031980000'])].index.tolist()
for col in chicago_race.columns:
if "Percent;" in col:
chicago_race.loc[zero_inds, col] = 0
# Coercing these demographic features to the 'float' type
for col in chicago_race.columns:
if "Percent;" in col:
chicago_race[col] = chicago_race[col].astype(float)
Now that we have data in the correct format with the correct type, we can start mapping out some features of interest. I'm not sure if a red-orange color scale is best for this data, but it's certainly striking.
fig, ax = plt.subplots(figsize=(14,14))
my_cmap='YlGn'
race_col = 'Percent; RACE - One race - White'
vmin = chicago_race[race_col].min()
vmax = chicago_race[race_col].max()
_ = chicago_race.plot(column=race_col,
cmap=my_cmap, ax=ax)
_ = ax.axis('off')
_ = ax.set_title("White Population: Percentage of Census Tract Pop. (Chicago)",
fontdict={'fontsize': '25', 'fontweight' : '3'})
_ = ax.annotate('Source: American Community Survey, 2015',
xy=(0.1, .1), xycoords='figure fraction',
horizontalalignment='left', verticalalignment='top',
fontsize=10, color='#555555')
sm = plt.cm.ScalarMappable(cmap=my_cmap, norm=plt.Normalize(vmin=vmin, vmax=vmax))
sm._A = []
cbar = fig.colorbar(sm, shrink=0.5)
plt.tight_layout()
col_names = il_acs_15.columns.tolist()
# col_names
cols = []
for col_name in col_names:
if "Margin of Error" not in col_name:
cols.append(col_name)
len(cols)
171
# cols
53.2+38.6+3.8+11.6-2.8
104.4
race_df = il_acs_15[['Id2',
'Percent; RACE - One race - White',
'Percent; RACE - One race - Black or African American',
'Percent; RACE - One race - Asian',
'Percent; HISPANIC OR LATINO AND RACE - Total population - Hispanic or Latino (of any race)']].copy()
hisp_cols = []
for col_name in col_names:
if "Percent; HISPANIC OR LATINO AND RACE" in col_name:
hisp_cols.append(col_name)
hisp_cols
['Percent; HISPANIC OR LATINO AND RACE - Total population', 'Percent; HISPANIC OR LATINO AND RACE - Total population - Hispanic or Latino (of any race)', 'Percent; HISPANIC OR LATINO AND RACE - Total population - Hispanic or Latino (of any race) - Mexican', 'Percent; HISPANIC OR LATINO AND RACE - Total population - Hispanic or Latino (of any race) - Puerto Rican', 'Percent; HISPANIC OR LATINO AND RACE - Total population - Hispanic or Latino (of any race) - Cuban', 'Percent; HISPANIC OR LATINO AND RACE - Total population - Hispanic or Latino (of any race) - Other Hispanic or Latino', 'Percent; HISPANIC OR LATINO AND RACE - Total population - Not Hispanic or Latino', 'Percent; HISPANIC OR LATINO AND RACE - Total population - Not Hispanic or Latino - White alone', 'Percent; HISPANIC OR LATINO AND RACE - Total population - Not Hispanic or Latino - Black or African American alone', 'Percent; HISPANIC OR LATINO AND RACE - Total population - Not Hispanic or Latino - American Indian and Alaska Native alone', 'Percent; HISPANIC OR LATINO AND RACE - Total population - Not Hispanic or Latino - Asian alone', 'Percent; HISPANIC OR LATINO AND RACE - Total population - Not Hispanic or Latino - Native Hawaiian and Other Pacific Islander alone', 'Percent; HISPANIC OR LATINO AND RACE - Total population - Not Hispanic or Latino - Some other race alone', 'Percent; HISPANIC OR LATINO AND RACE - Total population - Not Hispanic or Latino - Two or more races', 'Percent; HISPANIC OR LATINO AND RACE - Total population - Not Hispanic or Latino - Two or more races - Two races including Some other race', 'Percent; HISPANIC OR LATINO AND RACE - Total population - Not Hispanic or Latino - Two or more races - Two races excluding Some other race, and Three or more races', 'Percent; HISPANIC OR LATINO AND RACE - Total housing units']
il_acs_15[hisp_cols]
Percent; HISPANIC OR LATINO AND RACE - Total population | Percent; HISPANIC OR LATINO AND RACE - Total population - Hispanic or Latino (of any race) | Percent; HISPANIC OR LATINO AND RACE - Total population - Hispanic or Latino (of any race) - Mexican | Percent; HISPANIC OR LATINO AND RACE - Total population - Hispanic or Latino (of any race) - Puerto Rican | Percent; HISPANIC OR LATINO AND RACE - Total population - Hispanic or Latino (of any race) - Cuban | Percent; HISPANIC OR LATINO AND RACE - Total population - Hispanic or Latino (of any race) - Other Hispanic or Latino | Percent; HISPANIC OR LATINO AND RACE - Total population - Not Hispanic or Latino | Percent; HISPANIC OR LATINO AND RACE - Total population - Not Hispanic or Latino - White alone | Percent; HISPANIC OR LATINO AND RACE - Total population - Not Hispanic or Latino - Black or African American alone | Percent; HISPANIC OR LATINO AND RACE - Total population - Not Hispanic or Latino - American Indian and Alaska Native alone | Percent; HISPANIC OR LATINO AND RACE - Total population - Not Hispanic or Latino - Asian alone | Percent; HISPANIC OR LATINO AND RACE - Total population - Not Hispanic or Latino - Native Hawaiian and Other Pacific Islander alone | Percent; HISPANIC OR LATINO AND RACE - Total population - Not Hispanic or Latino - Some other race alone | Percent; HISPANIC OR LATINO AND RACE - Total population - Not Hispanic or Latino - Two or more races | Percent; HISPANIC OR LATINO AND RACE - Total population - Not Hispanic or Latino - Two or more races - Two races including Some other race | Percent; HISPANIC OR LATINO AND RACE - Total population - Not Hispanic or Latino - Two or more races - Two races excluding Some other race, and Three or more races | Percent; HISPANIC OR LATINO AND RACE - Total housing units | |
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
0 | 4106 | 11.6 | 6.6 | 2.8 | 0.0 | 2.2 | 88.4 | 44.6 | 37.0 | 0.0 | 3.8 | 0.0 | 0.3 | 2.8 | 0.3 | 2.4 | (X) |
1 | 7229 | 27.5 | 24.1 | 0.7 | 1.4 | 1.2 | 72.5 | 21.3 | 45.6 | 0.4 | 3.1 | 0.0 | 0.2 | 2.0 | 0.0 | 2.0 | (X) |
2 | 2304 | 26.4 | 18.6 | 2.2 | 0.7 | 5.0 | 73.6 | 35.5 | 28.1 | 0.0 | 7.7 | 0.0 | 0.0 | 2.3 | 0.8 | 1.5 | (X) |
3 | 6077 | 16.1 | 10.7 | 0.8 | 1.0 | 3.7 | 83.9 | 45.5 | 24.3 | 0.1 | 12.4 | 0.0 | 0.0 | 1.6 | 0.0 | 1.6 | (X) |
4 | 5011 | 8.3 | 5.8 | 0.5 | 0.7 | 1.3 | 91.7 | 69.2 | 12.2 | 0.0 | 6.5 | 0.0 | 0.7 | 3.0 | 0.9 | 2.1 | (X) |
5 | 3837 | 6.1 | 2.8 | 1.8 | 1.4 | 0.0 | 93.9 | 59.5 | 27.1 | 0.0 | 2.4 | 0.0 | 0.0 | 4.9 | 0.0 | 4.9 | (X) |
6 | 3413 | 14.9 | 10.3 | 1.1 | 0.4 | 3.1 | 85.1 | 52.3 | 16.9 | 0.0 | 13.9 | 0.0 | 0.0 | 2.0 | 0.6 | 1.3 | (X) |
7 | 2080 | 16.6 | 14.0 | 0.0 | 0.0 | 2.6 | 83.4 | 53.8 | 7.5 | 0.0 | 16.2 | 0.0 | 0.0 | 5.8 | 2.0 | 3.8 | (X) |
8 | 6558 | 27.1 | 14.3 | 2.3 | 3.7 | 6.8 | 72.9 | 41.6 | 25.9 | 0.0 | 2.2 | 0.0 | 0.2 | 2.9 | 0.0 | 2.9 | (X) |
9 | 3999 | 38.5 | 33.4 | 0.5 | 0.0 | 4.7 | 61.5 | 33.4 | 17.7 | 0.0 | 7.6 | 0.0 | 0.4 | 2.5 | 0.0 | 2.5 | (X) |
10 | 5163 | 46.8 | 44.2 | 0.5 | 0.0 | 2.1 | 53.2 | 25.8 | 19.4 | 0.0 | 4.6 | 0.0 | 0.5 | 3.0 | 0.0 | 3.0 | (X) |
11 | 3899 | 13.2 | 10.2 | 0.0 | 1.3 | 1.7 | 86.8 | 31.9 | 30.5 | 0.0 | 19.1 | 0.0 | 0.7 | 4.5 | 0.0 | 4.5 | (X) |
12 | 6634 | 10.1 | 5.8 | 2.3 | 0.0 | 2.0 | 89.9 | 53.6 | 12.2 | 0.0 | 21.7 | 0.0 | 0.0 | 2.4 | 0.0 | 2.4 | (X) |
13 | 5142 | 8.9 | 7.8 | 0.3 | 0.0 | 0.8 | 91.1 | 72.4 | 6.4 | 0.7 | 10.6 | 0.0 | 0.2 | 0.8 | 0.3 | 0.6 | (X) |
14 | 4886 | 18.1 | 14.7 | 1.6 | 0.0 | 1.8 | 81.9 | 52.9 | 13.7 | 0.0 | 12.7 | 0.0 | 0.3 | 2.3 | 0.0 | 2.3 | (X) |
15 | 4518 | 19.3 | 15.7 | 0.8 | 0.2 | 2.7 | 80.7 | 47.0 | 15.2 | 0.0 | 16.9 | 0.0 | 0.0 | 1.5 | 0.4 | 1.1 | (X) |
16 | 5794 | 26.1 | 19.1 | 0.0 | 0.0 | 6.9 | 73.9 | 25.7 | 17.1 | 0.0 | 21.3 | 0.0 | 0.4 | 9.4 | 1.3 | 8.1 | (X) |
17 | 6330 | 10.3 | 7.4 | 0.7 | 0.0 | 2.1 | 89.7 | 58.4 | 5.8 | 0.6 | 22.5 | 0.0 | 0.0 | 2.5 | 0.8 | 1.7 | (X) |
18 | 4113 | 24.1 | 19.8 | 1.1 | 0.0 | 3.2 | 75.9 | 30.5 | 9.4 | 0.0 | 32.5 | 0.0 | 1.4 | 2.2 | 0.7 | 1.5 | (X) |
19 | 1635 | 12.6 | 6.9 | 2.0 | 0.4 | 3.3 | 87.4 | 55.2 | 1.0 | 6.2 | 20.6 | 0.0 | 0.0 | 4.5 | 3.9 | 0.6 | (X) |
20 | 7833 | 17.3 | 15.8 | 0.5 | 0.0 | 1.0 | 82.7 | 50.2 | 3.5 | 0.0 | 24.7 | 0.0 | 0.0 | 4.3 | 1.7 | 2.6 | (X) |
21 | 4760 | 30.2 | 16.9 | 2.1 | 1.0 | 10.2 | 69.8 | 41.5 | 2.9 | 0.0 | 22.5 | 0.0 | 0.0 | 2.9 | 0.5 | 2.4 | (X) |
22 | 7508 | 15.0 | 13.6 | 0.2 | 0.0 | 1.2 | 85.0 | 29.0 | 5.9 | 0.0 | 46.7 | 0.0 | 0.0 | 3.3 | 0.0 | 3.3 | (X) |
23 | 5004 | 30.1 | 25.0 | 1.0 | 0.0 | 4.2 | 69.9 | 24.2 | 21.5 | 0.0 | 22.1 | 0.0 | 0.0 | 2.1 | 0.0 | 2.1 | (X) |
24 | 4155 | 11.7 | 7.4 | 2.1 | 0.6 | 1.7 | 88.3 | 50.9 | 17.6 | 0.0 | 19.4 | 0.0 | 0.0 | 0.4 | 0.2 | 0.2 | (X) |
25 | 3613 | 19.3 | 17.7 | 0.0 | 0.4 | 1.1 | 80.7 | 46.4 | 20.6 | 0.0 | 10.4 | 0.0 | 0.8 | 2.5 | 0.4 | 2.1 | (X) |
26 | 2880 | 15.1 | 4.3 | 4.1 | 0.3 | 6.4 | 84.9 | 44.8 | 22.8 | 0.4 | 14.2 | 0.0 | 0.5 | 2.3 | 0.0 | 2.3 | (X) |
27 | 2347 | 16.2 | 9.8 | 0.4 | 0.2 | 5.8 | 83.8 | 48.2 | 14.8 | 0.2 | 17.2 | 0.7 | 0.0 | 2.7 | 0.6 | 2.0 | (X) |
28 | 3487 | 10.6 | 6.4 | 0.6 | 1.6 | 2.1 | 89.4 | 50.5 | 12.2 | 0.0 | 16.9 | 0.0 | 0.2 | 9.5 | 1.6 | 8.0 | (X) |
29 | 4978 | 16.6 | 11.4 | 4.3 | 0.3 | 0.6 | 83.4 | 76.0 | 3.4 | 0.0 | 3.6 | 0.0 | 0.0 | 0.3 | 0.0 | 0.3 | (X) |
... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... |
1290 | 4017 | 83.4 | 76.7 | 2.1 | 0.0 | 4.5 | 16.6 | 10.7 | 3.8 | 0.0 | 0.6 | 0.0 | 0.0 | 1.5 | 0.0 | 1.5 | (X) |
1291 | 1213 | 10.6 | 3.5 | 7.2 | 0.0 | 0.0 | 89.4 | 2.1 | 86.9 | 0.0 | 0.3 | 0.0 | 0.0 | 0.0 | 0.0 | 0.0 | (X) |
1292 | 3029 | 5.1 | 4.3 | 0.8 | 0.0 | 0.0 | 94.9 | 0.9 | 92.6 | 0.0 | 0.4 | 0.0 | 0.5 | 0.6 | 0.0 | 0.6 | (X) |
1293 | 745 | 0.0 | 0.0 | 0.0 | 0.0 | 0.0 | 100.0 | 2.0 | 98.0 | 0.0 | 0.0 | 0.0 | 0.0 | 0.0 | 0.0 | 0.0 | (X) |
1294 | 1607 | 46.3 | 43.4 | 2.9 | 0.0 | 0.0 | 53.7 | 3.3 | 49.4 | 0.0 | 0.0 | 0.0 | 0.0 | 1.0 | 0.0 | 1.0 | (X) |
1295 | 2599 | 2.4 | 1.5 | 0.7 | 0.0 | 0.2 | 97.6 | 0.0 | 95.3 | 0.0 | 0.0 | 0.0 | 0.5 | 1.8 | 0.0 | 1.8 | (X) |
1296 | 6158 | 13.7 | 8.4 | 1.7 | 0.1 | 3.6 | 86.3 | 49.7 | 12.9 | 0.0 | 20.0 | 0.0 | 0.4 | 3.3 | 0.2 | 3.1 | (X) |
1297 | 2999 | 7.8 | 4.4 | 1.4 | 0.5 | 1.6 | 92.2 | 32.5 | 34.3 | 0.0 | 21.5 | 0.0 | 0.5 | 3.3 | 1.3 | 2.0 | (X) |
1298 | 7111 | 39.4 | 15.1 | 14.9 | 0.0 | 9.4 | 60.6 | 0.7 | 59.1 | 0.0 | 0.4 | 0.0 | 0.0 | 0.4 | 0.0 | 0.4 | (X) |
1299 | 2614 | 15.5 | 0.4 | 9.9 | 1.2 | 4.0 | 84.5 | 57.0 | 13.6 | 0.0 | 11.4 | 0.0 | 0.0 | 2.5 | 0.4 | 2.1 | (X) |
1300 | 3754 | 10.3 | 5.1 | 2.2 | 0.0 | 3.0 | 89.7 | 70.2 | 9.9 | 0.0 | 5.1 | 0.0 | 0.2 | 4.3 | 0.0 | 4.3 | (X) |
1301 | 3102 | 0.0 | 0.0 | 0.0 | 0.0 | 0.0 | 100.0 | 0.0 | 100.0 | 0.0 | 0.0 | 0.0 | 0.0 | 0.0 | 0.0 | 0.0 | (X) |
1302 | 2286 | 0.3 | 0.3 | 0.0 | 0.0 | 0.0 | 99.7 | 0.1 | 99.6 | 0.0 | 0.0 | 0.0 | 0.0 | 0.0 | 0.0 | 0.0 | (X) |
1303 | 4852 | 40.3 | 35.2 | 3.5 | 0.0 | 1.6 | 59.7 | 46.0 | 3.3 | 0.0 | 9.2 | 0.0 | 0.0 | 1.2 | 0.2 | 1.0 | (X) |
1304 | 7446 | 90.1 | 80.7 | 1.3 | 0.5 | 7.7 | 9.9 | 4.4 | 0.9 | 0.1 | 4.3 | 0.0 | 0.2 | 0.0 | 0.0 | 0.0 | (X) |
1305 | 2412 | 17.7 | 9.7 | 6.9 | 0.0 | 1.1 | 82.3 | 4.1 | 75.3 | 0.2 | 2.7 | 0.0 | 0.0 | 0.0 | 0.0 | 0.0 | (X) |
1306 | 2848 | 2.5 | 2.1 | 0.4 | 0.0 | 0.0 | 97.5 | 0.0 | 97.2 | 0.2 | 0.0 | 0.0 | 0.0 | 0.0 | 0.0 | 0.0 | (X) |
1307 | 1931 | 1.7 | 1.2 | 0.3 | 0.0 | 0.2 | 98.3 | 5.8 | 88.6 | 0.0 | 1.7 | 0.0 | 0.0 | 2.2 | 0.3 | 2.0 | (X) |
1308 | 2538 | 85.2 | 83.8 | 0.0 | 0.0 | 1.4 | 14.8 | 10.6 | 1.5 | 0.2 | 1.5 | 0.0 | 0.0 | 0.9 | 0.0 | 0.9 | (X) |
1309 | 1848 | 43.5 | 35.4 | 8.1 | 0.0 | 0.0 | 56.5 | 7.8 | 47.2 | 0.0 | 0.5 | 0.0 | 0.5 | 0.4 | 0.3 | 0.1 | (X) |
1310 | 1281 | 4.1 | 3.5 | 0.6 | 0.0 | 0.0 | 95.9 | 4.0 | 80.9 | 0.0 | 3.1 | 0.0 | 0.0 | 7.9 | 0.0 | 7.9 | (X) |
1311 | 8572 | 22.7 | 20.5 | 1.0 | 0.2 | 1.1 | 77.3 | 10.0 | 66.4 | 0.4 | 0.4 | 0.0 | 0.0 | 0.0 | 0.0 | 0.0 | (X) |
1312 | 2639 | 5.2 | 3.1 | 1.0 | 0.0 | 1.1 | 94.8 | 3.0 | 89.3 | 0.0 | 1.3 | 0.0 | 0.0 | 1.2 | 0.0 | 1.2 | (X) |
1313 | 2440 | 26.0 | 20.5 | 1.1 | 0.8 | 3.5 | 74.0 | 64.9 | 1.4 | 0.2 | 4.2 | 0.0 | 0.4 | 2.9 | 0.0 | 2.9 | (X) |
1314 | 1853 | 20.6 | 12.7 | 1.6 | 0.0 | 6.3 | 79.4 | 23.6 | 46.3 | 0.0 | 9.2 | 0.0 | 0.0 | 0.3 | 0.0 | 0.3 | (X) |
1315 | 3630 | 3.9 | 3.4 | 0.2 | 0.0 | 0.3 | 96.1 | 1.3 | 92.6 | 0.0 | 1.9 | 0.0 | 0.0 | 0.3 | 0.0 | 0.3 | (X) |
1316 | 0 | - | - | - | - | - | - | - | - | - | - | - | - | - | - | - | (X) |
1317 | 0 | - | - | - | - | - | - | - | - | - | - | - | - | - | - | - | (X) |
1318 | 0 | - | - | - | - | - | - | - | - | - | - | - | - | - | - | - | (X) |
1319 | 2717534 | 29.1 | 21.7 | 3.8 | 0.3 | 3.2 | 70.9 | 32.2 | 30.9 | 0.1 | 5.9 | 0.0 | 0.2 | 1.6 | 0.1 | 1.5 | (X) |
1320 rows × 17 columns
CSV_PATH = os.path.join('data', 'hacknight_ticket_sample_data_2015.csv')
df = pd.read_csv(CSV_PATH,low_memory=False, parse_dates=['issue_date', 'ticket_queue_date'])
CSV_PATH = os.path.join('data', 'hacknight_sample_data_geocode_cleaned.csv')
addrs_df = pd.read_csv(CSV_PATH)
geocoded_df = pd.merge(left=df, right=addrs_df, how='inner', on='address')
geocoded_df.head()
ticket_number | issue_date | violation_location | license_plate_number | license_plate_state | license_plate_type | zipcode | violation_code | violation_description | unit | unit_description | vehicle_make | fine_level1_amount | fine_level2_amount | current_amount_due | total_payments | ticket_queue | ticket_queue_date | notice_level | hearing_disposition | notice_number | officer | address | lat | lng | |
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
0 | 9188814621 | 2015-05-07 13:52:00 | 2134 S ARCHER AV | 7c189a16ef79db9413c1f46b7e5d1712e5c0c1575be352... | MI | PAS | 48103 | 0964190A | EXP. METER NON-CENTRAL BUSINESS DISTRICT | 498 | DOF | BUIC | 50 | 100 | 0.0 | 50.0 | Paid | 2015-05-13 | NaN | NaN | 0 | 798 | 2100 s archer av, chicago, il | 41.854262 | -87.631986 |
1 | 9188814621 | 2015-05-07 13:52:00 | 2134 S ARCHER AV | 7c189a16ef79db9413c1f46b7e5d1712e5c0c1575be352... | MI | PAS | 48103 | 0964190A | EXP. METER NON-CENTRAL BUSINESS DISTRICT | 498 | DOF | BUIC | 50 | 100 | 0.0 | 50.0 | Paid | 2015-05-13 | NaN | NaN | 0 | 798 | 2100 s archer av, chicago, il | 41.854262 | -87.631986 |
2 | 9188814621 | 2015-05-07 13:52:00 | 2134 S ARCHER AV | 7c189a16ef79db9413c1f46b7e5d1712e5c0c1575be352... | MI | PAS | 48103 | 0964190A | EXP. METER NON-CENTRAL BUSINESS DISTRICT | 498 | DOF | BUIC | 50 | 100 | 0.0 | 50.0 | Paid | 2015-05-13 | NaN | NaN | 0 | 798 | 2100 s archer av, chicago, il | 41.854262 | -87.631986 |
3 | 9188814621 | 2015-05-07 13:52:00 | 2134 S ARCHER AV | 7c189a16ef79db9413c1f46b7e5d1712e5c0c1575be352... | MI | PAS | 48103 | 0964190A | EXP. METER NON-CENTRAL BUSINESS DISTRICT | 498 | DOF | BUIC | 50 | 100 | 0.0 | 50.0 | Paid | 2015-05-13 | NaN | NaN | 0 | 798 | 2100 s archer av, chicago, il | 41.854262 | -87.631986 |
4 | 9188814621 | 2015-05-07 13:52:00 | 2134 S ARCHER AV | 7c189a16ef79db9413c1f46b7e5d1712e5c0c1575be352... | MI | PAS | 48103 | 0964190A | EXP. METER NON-CENTRAL BUSINESS DISTRICT | 498 | DOF | BUIC | 50 | 100 | 0.0 | 50.0 | Paid | 2015-05-13 | NaN | NaN | 0 | 798 | 2100 s archer av, chicago, il | 41.854262 | -87.631986 |
point_maker = lambda x: Point(x['lng'], x['lat'])
geocoded_df['geometry'] = geocoded_df.apply(point_maker, axis=1)
def assign_census_tracts(df, shape_df):
"""Joins DataFrame with region shapefile.
This function takes a DataFrame containing latitude and longitude values and
a GeopandasDataFrame that describes regions that those lat-long pairs are sorted
into. This should facilitate pairing with Census data that can introduce other
features like racial demographics.
Parameters
----------
df : pandas.DataFrame or dask.DataFrame
DataFrame containing latitudes, longitudes, and location_id columns.
shape_df: a GeopandasDataFrame containing regions to map to.
Name of series to return.
"""
# make a copy since we will modify lats and lons
localdf = df.copy()
localdf['lng'] = localdf['lng'].fillna(value=0.)
localdf['lat'] = localdf['lat'].fillna(value=0.)
shape_df = shape_df.to_crs({'init': 'epsg:4326'})
try:
local_gdf = gpd.GeoDataFrame(
localdf, crs={'init': 'epsg:4326'},
geometry=[Point(xy) for xy in zip(localdf['lng'], localdf['lat'])]
)
local_gdf = gpd.sjoin(local_gdf, shape_df, how='left', op='within')
return local_gdf
except ValueError as ve:
print(ve)
print(ve.stacktrace())
series = localdf['lng']
series = np.nan
return series
ZIP_SHP_PATH = os.path.join('zip://', 'data', 'Boundaries - Census Tracts - 2010.zip')
coord_system = {'init': 'epsg:4326'}
chicago_census_tracts = gpd.read_file(ZIP_SHP_PATH).to_crs(coord_system)
chicago_census_tracts.plot(figsize=(15,10))
<matplotlib.axes._subplots.AxesSubplot at 0x258beb713c8>
full_df = assign_census_tracts(geocoded_df, chicago_census_tracts)
full_df.head()
ticket_number | issue_date | violation_location | license_plate_number | license_plate_state | license_plate_type | zipcode | violation_code | violation_description | unit | unit_description | vehicle_make | fine_level1_amount | fine_level2_amount | current_amount_due | total_payments | ticket_queue | ticket_queue_date | notice_level | hearing_disposition | notice_number | officer | address | lat | lng | geometry | index_right | statefp10 | countyfp10 | tractce10 | namelsad10 | commarea | geoid10 | commarea_n | name10 | notes | |
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
0 | 9188814621 | 2015-05-07 13:52:00 | 2134 S ARCHER AV | 7c189a16ef79db9413c1f46b7e5d1712e5c0c1575be352... | MI | PAS | 48103 | 0964190A | EXP. METER NON-CENTRAL BUSINESS DISTRICT | 498 | DOF | BUIC | 50 | 100 | 0.0 | 50.0 | Paid | 2015-05-13 | NaN | NaN | 0 | 798 | 2100 s archer av, chicago, il | 41.854262 | -87.631986 | POINT (-87.63198586874586 41.85426174412816) | 2.0 | 17 | 031 | 841100 | Census Tract 8411 | 34 | 17031841100 | 34.0 | 8411 | None |
1 | 9188814621 | 2015-05-07 13:52:00 | 2134 S ARCHER AV | 7c189a16ef79db9413c1f46b7e5d1712e5c0c1575be352... | MI | PAS | 48103 | 0964190A | EXP. METER NON-CENTRAL BUSINESS DISTRICT | 498 | DOF | BUIC | 50 | 100 | 0.0 | 50.0 | Paid | 2015-05-13 | NaN | NaN | 0 | 798 | 2100 s archer av, chicago, il | 41.854262 | -87.631986 | POINT (-87.63198586874586 41.85426174412816) | 2.0 | 17 | 031 | 841100 | Census Tract 8411 | 34 | 17031841100 | 34.0 | 8411 | None |
2 | 9188814621 | 2015-05-07 13:52:00 | 2134 S ARCHER AV | 7c189a16ef79db9413c1f46b7e5d1712e5c0c1575be352... | MI | PAS | 48103 | 0964190A | EXP. METER NON-CENTRAL BUSINESS DISTRICT | 498 | DOF | BUIC | 50 | 100 | 0.0 | 50.0 | Paid | 2015-05-13 | NaN | NaN | 0 | 798 | 2100 s archer av, chicago, il | 41.854262 | -87.631986 | POINT (-87.63198586874586 41.85426174412816) | 2.0 | 17 | 031 | 841100 | Census Tract 8411 | 34 | 17031841100 | 34.0 | 8411 | None |
3 | 9188814621 | 2015-05-07 13:52:00 | 2134 S ARCHER AV | 7c189a16ef79db9413c1f46b7e5d1712e5c0c1575be352... | MI | PAS | 48103 | 0964190A | EXP. METER NON-CENTRAL BUSINESS DISTRICT | 498 | DOF | BUIC | 50 | 100 | 0.0 | 50.0 | Paid | 2015-05-13 | NaN | NaN | 0 | 798 | 2100 s archer av, chicago, il | 41.854262 | -87.631986 | POINT (-87.63198586874586 41.85426174412816) | 2.0 | 17 | 031 | 841100 | Census Tract 8411 | 34 | 17031841100 | 34.0 | 8411 | None |
4 | 9188814621 | 2015-05-07 13:52:00 | 2134 S ARCHER AV | 7c189a16ef79db9413c1f46b7e5d1712e5c0c1575be352... | MI | PAS | 48103 | 0964190A | EXP. METER NON-CENTRAL BUSINESS DISTRICT | 498 | DOF | BUIC | 50 | 100 | 0.0 | 50.0 | Paid | 2015-05-13 | NaN | NaN | 0 | 798 | 2100 s archer av, chicago, il | 41.854262 | -87.631986 | POINT (-87.63198586874586 41.85426174412816) | 2.0 | 17 | 031 | 841100 | Census Tract 8411 | 34 | 17031841100 | 34.0 | 8411 | None |
race_df.info()
<class 'pandas.core.frame.DataFrame'> RangeIndex: 1320 entries, 0 to 1319 Data columns (total 5 columns): Id2 1320 non-null int64 Percent; RACE - One race - White 1320 non-null object Percent; RACE - One race - Black or African American 1320 non-null object Percent; RACE - One race - Asian 1320 non-null object Percent; HISPANIC OR LATINO AND RACE - Total population - Hispanic or Latino (of any race) 1320 non-null object dtypes: int64(1), object(4) memory usage: 51.6+ KB
race_df.head()
Id2 | Percent; RACE - One race - White | Percent; RACE - One race - Black or African American | Percent; RACE - One race - Asian | Percent; HISPANIC OR LATINO AND RACE - Total population - Hispanic or Latino (of any race) | |
---|---|---|---|---|---|
0 | 17031010100 | 53.2 | 38.6 | 3.8 | 11.6 |
1 | 17031010201 | 46.9 | 45.6 | 3.1 | 27.5 |
2 | 17031010202 | 51.1 | 29.3 | 8.0 | 26.4 |
3 | 17031010300 | 57.2 | 25.4 | 12.4 | 16.1 |
4 | 17031010400 | 74.7 | 13.2 | 6.7 | 8.3 |
race_df.loc['Id2'] = race_df['Id2'].astype(str)
race_df[race_df['Id2'].isnull()]
Id2 | Percent; RACE - One race - White | Percent; RACE - One race - Black or African American | Percent; RACE - One race - Asian | Percent; HISPANIC OR LATINO AND RACE - Total population - Hispanic or Latino (of any race) | |
---|---|---|---|---|---|
Id2 | NaN | NaN | NaN | NaN | NaN |
race_df.drop(index=['Id2'], inplace=True)
race_df[race_df['Id2'].isnull()]
Id2 | Percent; RACE - One race - White | Percent; RACE - One race - Black or African American | Percent; RACE - One race - Asian | Percent; HISPANIC OR LATINO AND RACE - Total population - Hispanic or Latino (of any race) |
---|
race_df['Id2'] = race_df['Id2'].astype(str)
race_df.info()
<class 'pandas.core.frame.DataFrame'> Index: 1320 entries, 0 to 1319 Data columns (total 5 columns): Id2 1320 non-null object Percent; RACE - One race - White 1320 non-null object Percent; RACE - One race - Black or African American 1320 non-null object Percent; RACE - One race - Asian 1320 non-null object Percent; HISPANIC OR LATINO AND RACE - Total population - Hispanic or Latino (of any race) 1320 non-null object dtypes: object(5) memory usage: 61.9+ KB
chicago_census_tracts['geoid10'] = chicago_census_tracts['geoid10'].astype(str)
chicago_census_tracts.info()
<class 'geopandas.geodataframe.GeoDataFrame'> RangeIndex: 801 entries, 0 to 800 Data columns (total 10 columns): statefp10 801 non-null object countyfp10 801 non-null object tractce10 801 non-null object namelsad10 801 non-null object commarea 801 non-null object geoid10 801 non-null object commarea_n 801 non-null float64 name10 801 non-null object notes 12 non-null object geometry 801 non-null object dtypes: float64(1), object(9) memory usage: 62.7+ KB
chicago_census_tracts[chicago_census_tracts['geoid10'] == '17031010100']
statefp10 | countyfp10 | tractce10 | namelsad10 | commarea | geoid10 | commarea_n | name10 | notes | geometry | |
---|---|---|---|---|---|---|---|---|---|---|
339 | 17 | 031 | 010100 | Census Tract 101 | 1 | 17031010100 | 1.0 | 101 | None | POLYGON ((-87.66368000002299 42.01939800001483... |
pd.merge(left=chicago_census_tracts, right=race_df, left_on='geoid10', right_on='Id2', how='left')
statefp10 | countyfp10 | tractce10 | namelsad10 | commarea | geoid10 | commarea_n | name10 | notes | geometry | Id2 | Percent; RACE - One race - White | Percent; RACE - One race - Black or African American | Percent; RACE - One race - Asian | Percent; HISPANIC OR LATINO AND RACE - Total population - Hispanic or Latino (of any race) | |
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
0 | 17 | 031 | 842400 | Census Tract 8424 | 44 | 17031842400 | 44.0 | 8424 | None | POLYGON ((-87.62404799998049 41.73021699998396... | NaN | NaN | NaN | NaN | NaN |
1 | 17 | 031 | 840300 | Census Tract 8403 | 59 | 17031840300 | 59.0 | 8403 | None | POLYGON ((-87.6860799999848 41.82295600001154,... | NaN | NaN | NaN | NaN | NaN |
2 | 17 | 031 | 841100 | Census Tract 8411 | 34 | 17031841100 | 34.0 | 8411 | None | POLYGON ((-87.62934700001183 41.8527970000265,... | NaN | NaN | NaN | NaN | NaN |
3 | 17 | 031 | 841200 | Census Tract 8412 | 31 | 17031841200 | 31.0 | 8412 | None | POLYGON ((-87.68813499997718 41.85569099999095... | NaN | NaN | NaN | NaN | NaN |
4 | 17 | 031 | 838200 | Census Tract 8382 | 28 | 17031838200 | 28.0 | 8382 | None | POLYGON ((-87.66781999997529 41.8741839999791,... | NaN | NaN | NaN | NaN | NaN |
5 | 17 | 031 | 650301 | Census Tract 6503.01 | 65 | 17031650301 | 65.0 | 6503.01 | None | POLYGON ((-87.73706400002477 41.77120399998377... | NaN | NaN | NaN | NaN | NaN |
6 | 17 | 031 | 530503 | Census Tract 5305.03 | 53 | 17031530503 | 53.0 | 5305.03 | None | POLYGON ((-87.64386399998179 41.66321000002088... | NaN | NaN | NaN | NaN | NaN |
7 | 17 | 031 | 760803 | Census Tract 7608.03 | 76 | 17031760803 | 76.0 | 7608.03 | None | POLYGON ((-87.83844200004106 41.97019999997084... | NaN | NaN | NaN | NaN | NaN |
8 | 17 | 031 | 540102 | Census Tract 5401.02 | 54 | 17031540102 | 54.0 | 5401.02 | None | POLYGON ((-87.6188529999847 41.65641699997538,... | NaN | NaN | NaN | NaN | NaN |
9 | 17 | 031 | 540101 | Census Tract 5401.01 | 54 | 17031540101 | 54.0 | 5401.01 | None | POLYGON ((-87.61891699998056 41.65640000000292... | NaN | NaN | NaN | NaN | NaN |
10 | 17 | 031 | 440201 | Census Tract 4402.01 | 44 | 17031440201 | 44.0 | 4402.01 | None | POLYGON ((-87.61235000001714 41.74567799999993... | NaN | NaN | NaN | NaN | NaN |
11 | 17 | 031 | 839000 | Census Tract 8390 | 32 | 17031839000 | 32.0 | 8390 | None | POLYGON ((-87.63312200003458 41.87448800002695... | NaN | NaN | NaN | NaN | NaN |
12 | 17 | 031 | 030601 | Census Tract 306.01 | 77 | 17031030601 | 77.0 | 306.01 | None | POLYGON ((-87.6543830000042 41.99020200000391,... | NaN | NaN | NaN | NaN | NaN |
13 | 17 | 031 | 030604 | Census Tract 306.04 | 77 | 17031030604 | 77.0 | 306.04 | None | POLYGON ((-87.64890400001316 41.98805300003046... | NaN | NaN | NaN | NaN | NaN |
14 | 17 | 031 | 020801 | Census Tract 208.01 | 2 | 17031020801 | 2.0 | 208.01 | None | POLYGON ((-87.6900509999568 41.98316600000329,... | NaN | NaN | NaN | NaN | NaN |
15 | 17 | 031 | 843300 | Census Tract 8433 | 29 | 17031843300 | 29.0 | 8433 | None | POLYGON ((-87.68821699998962 41.85933700002633... | NaN | NaN | NaN | NaN | NaN |
16 | 17 | 031 | 080202 | Census Tract 802.02 | 8 | 17031080202 | 8.0 | 802.02 | None | POLYGON ((-87.63250099997225 41.9077530000167,... | NaN | NaN | NaN | NaN | NaN |
17 | 17 | 031 | 070102 | Census Tract 701.02 | 7 | 17031070102 | 7.0 | 701.02 | None | POLYGON ((-87.64134300001398 41.93286999998789... | NaN | NaN | NaN | NaN | NaN |
18 | 17 | 031 | 031501 | Census Tract 315.01 | 3 | 17031031501 | 3.0 | 315.01 | None | POLYGON ((-87.65001900000163 41.96548800002778... | NaN | NaN | NaN | NaN | NaN |
19 | 17 | 031 | 031502 | Census Tract 315.02 | 3 | 17031031502 | 3.0 | 315.02 | None | POLYGON ((-87.64998799995692 41.96451299999013... | NaN | NaN | NaN | NaN | NaN |
20 | 17 | 031 | 834900 | Census Tract 8349 | 67 | 17031834900 | 67.0 | 8349 | None | POLYGON ((-87.65445700000026 41.77796299997031... | NaN | NaN | NaN | NaN | NaN |
21 | 17 | 031 | 834800 | Census Tract 8348 | 68 | 17031834800 | 68.0 | 8348 | None | POLYGON ((-87.6496539999827 41.78006600001602,... | NaN | NaN | NaN | NaN | NaN |
22 | 17 | 031 | 160502 | Census Tract 1605.02 | 16 | 17031160502 | 16.0 | 1605.02 | None | POLYGON ((-87.71731099997037 41.95743799998775... | NaN | NaN | NaN | NaN | NaN |
23 | 17 | 031 | 140702 | Census Tract 1407.02 | 14 | 17031140702 | 14.0 | 1407.02 | None | POLYGON ((-87.71330799996295 41.96658299997856... | NaN | NaN | NaN | NaN | NaN |
24 | 17 | 031 | 842000 | Census Tract 8420 | 35 | 17031842000 | 35.0 | 8420 | None | POLYGON ((-87.62905399997636 41.83827300000528... | NaN | NaN | NaN | NaN | NaN |
25 | 17 | 031 | 150402 | Census Tract 1504.02 | 15 | 17031150402 | 15.0 | 1504.02 | None | POLYGON ((-87.77703600004233 41.96080600000759... | NaN | NaN | NaN | NaN | NaN |
26 | 17 | 031 | 834400 | Census Tract 8344 | 42 | 17031834400 | 42.0 | 8344 | None | POLYGON ((-87.59170000000151 41.77691800000404... | NaN | NaN | NaN | NaN | NaN |
27 | 17 | 031 | 040201 | Census Tract 402.01 | 4 | 17031040201 | 4.0 | 402.01 | None | POLYGON ((-87.69876200001328 41.97072300001417... | NaN | NaN | NaN | NaN | NaN |
28 | 17 | 031 | 040202 | Census Tract 402.02 | 4 | 17031040202 | 4.0 | 402.02 | None | POLYGON ((-87.6916029999892 41.97587200002319,... | NaN | NaN | NaN | NaN | NaN |
29 | 17 | 031 | 020702 | Census Tract 207.02 | 2 | 17031020702 | 2.0 | 207.02 | None | POLYGON ((-87.70959900002015 41.99175000001063... | NaN | NaN | NaN | NaN | NaN |
... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... |
771 | 17 | 031 | 291200 | Census Tract 2912 | 29 | 17031291200 | 29.0 | 2912 | None | POLYGON ((-87.7127710000351 41.85899999996719,... | NaN | NaN | NaN | NaN | NaN |
772 | 17 | 031 | 620300 | Census Tract 6203 | 62 | 17031620300 | 62.0 | 6203 | None | POLYGON ((-87.72309700001856 41.7909409999788,... | NaN | NaN | NaN | NaN | NaN |
773 | 17 | 031 | 620400 | Census Tract 6204 | 62 | 17031620400 | 62.0 | 6204 | None | POLYGON ((-87.71312000003439 41.78609199996718... | NaN | NaN | NaN | NaN | NaN |
774 | 17 | 031 | 630100 | Census Tract 6301 | 63 | 17031630100 | 63.0 | 6301 | None | POLYGON ((-87.67901500004358 41.80482499999695... | NaN | NaN | NaN | NaN | NaN |
775 | 17 | 031 | 630300 | Census Tract 6303 | 63 | 17031630300 | 63.0 | 6303 | None | POLYGON ((-87.7134670000447 41.79520500000756,... | NaN | NaN | NaN | NaN | NaN |
776 | 17 | 031 | 630400 | Census Tract 6304 | 63 | 17031630400 | 63.0 | 6304 | None | POLYGON ((-87.69398799996556 41.80054200001116... | NaN | NaN | NaN | NaN | NaN |
777 | 17 | 031 | 630500 | Census Tract 6305 | 63 | 17031630500 | 63.0 | 6305 | None | POLYGON ((-87.68417800003391 41.79933399999008... | NaN | NaN | NaN | NaN | NaN |
778 | 17 | 031 | 110300 | Census Tract 1103 | 11 | 17031110300 | 11.0 | 1103 | None | POLYGON ((-87.77811600002528 41.97922099998399... | NaN | NaN | NaN | NaN | NaN |
779 | 17 | 031 | 110400 | Census Tract 1104 | 11 | 17031110400 | 11.0 | 1104 | None | POLYGON ((-87.76516900004339 41.97158399998364... | NaN | NaN | NaN | NaN | NaN |
780 | 17 | 031 | 120100 | Census Tract 1201 | 12 | 17031120100 | 12.0 | 1201 | None | POLYGON ((-87.77367200001376 41.99292600001029... | NaN | NaN | NaN | NaN | NaN |
781 | 17 | 031 | 120200 | Census Tract 1202 | 12 | 17031120200 | 12.0 | 1202 | None | POLYGON ((-87.74884400001038 41.98364299996826... | NaN | NaN | NaN | NaN | NaN |
782 | 17 | 031 | 271400 | Census Tract 2714 | 27 | 17031271400 | 27.0 | 2714 | None | POLYGON ((-87.71080299996187 41.87426299996504... | NaN | NaN | NaN | NaN | NaN |
783 | 17 | 031 | 280100 | Census Tract 2801 | 28 | 17031280100 | 28.0 | 2801 | None | POLYGON ((-87.64571900003747 41.88179600000515... | NaN | NaN | NaN | NaN | NaN |
784 | 17 | 031 | 280800 | Census Tract 2808 | 28 | 17031280800 | 28.0 | 2808 | None | POLYGON ((-87.6864299999679 41.88111400003041,... | NaN | NaN | NaN | NaN | NaN |
785 | 17 | 031 | 281900 | Census Tract 2819 | 28 | 17031281900 | 28.0 | 2819 | None | POLYGON ((-87.64592199996342 41.88178900001063... | NaN | NaN | NaN | NaN | NaN |
786 | 17 | 031 | 550100 | Census Tract 5501 | 55 | 17031550100 | 55.0 | 5501 | None | POLYGON ((-87.52481300004604 41.6869379999733,... | NaN | NaN | NaN | NaN | NaN |
787 | 17 | 031 | 611500 | Census Tract 6115 | 61 | 17031611500 | 61.0 | 6115 | None | POLYGON ((-87.6791730000365 41.80475599998746,... | NaN | NaN | NaN | NaN | NaN |
788 | 17 | 031 | 611800 | Census Tract 6118 | 61 | 17031611800 | 61.0 | 6118 | None | POLYGON ((-87.66951900000873 41.79669000001066... | NaN | NaN | NaN | NaN | NaN |
789 | 17 | 031 | 611900 | Census Tract 6119 | 61 | 17031611900 | 61.0 | 6119 | None | POLYGON ((-87.65491099997799 41.79598999999962... | NaN | NaN | NaN | NaN | NaN |
790 | 17 | 031 | 612000 | Census Tract 6120 | 61 | 17031612000 | 61.0 | 6120 | None | POLYGON ((-87.6501169999635 41.79823400001716,... | NaN | NaN | NaN | NaN | NaN |
791 | 17 | 031 | 620100 | Census Tract 6201 | 62 | 17031620100 | 62.0 | 6201 | None | POLYGON ((-87.71347400003852 41.79565199999381... | NaN | NaN | NaN | NaN | NaN |
792 | 17 | 031 | 620200 | Census Tract 6202 | 62 | 17031620200 | 62.0 | 6202 | None | POLYGON ((-87.73306200000724 41.79661200001753... | NaN | NaN | NaN | NaN | NaN |
793 | 17 | 031 | 070200 | Census Tract 702 | 7 | 17031070200 | 7.0 | 702 | None | POLYGON ((-87.64551400000029 41.93278800001222... | NaN | NaN | NaN | NaN | NaN |
794 | 17 | 031 | 070400 | Census Tract 704 | 7 | 17031070400 | 7.0 | 704 | None | POLYGON ((-87.65745700003984 41.93257799999479... | NaN | NaN | NaN | NaN | NaN |
795 | 17 | 031 | 070500 | Census Tract 705 | 7 | 17031070500 | 7.0 | 705 | None | POLYGON ((-87.66349399996524 41.93036099997366... | NaN | NaN | NaN | NaN | NaN |
796 | 17 | 031 | 071000 | Census Tract 710 | 7 | 17031071000 | 7.0 | 710 | None | POLYGON ((-87.65338399996253 41.91856199998072... | NaN | NaN | NaN | NaN | NaN |
797 | 17 | 031 | 071200 | Census Tract 712 | 7 | 17031071200 | 7.0 | 712 | None | POLYGON ((-87.64378699999278 41.92188799997481... | NaN | NaN | NaN | NaN | NaN |
798 | 17 | 031 | 130300 | Census Tract 1303 | 13 | 17031130300 | 13.0 | 1303 | None | POLYGON ((-87.71436299999318 41.9829969999959,... | NaN | NaN | NaN | NaN | NaN |
799 | 17 | 031 | 292200 | Census Tract 2922 | 29 | 17031292200 | 29.0 | 2922 | None | POLYGON ((-87.71317299997403 41.85523099997786... | NaN | NaN | NaN | NaN | NaN |
800 | 17 | 031 | 630900 | Census Tract 6309 | 63 | 17031630900 | 63.0 | 6309 | None | POLYGON ((-87.71128900002743 41.7933979999645,... | NaN | NaN | NaN | NaN | NaN |
801 rows × 15 columns
chicago_census_tracts.head()
statefp10 | countyfp10 | tractce10 | namelsad10 | commarea | geoid10 | commarea_n | name10 | notes | geometry | |
---|---|---|---|---|---|---|---|---|---|---|
0 | 17 | 031 | 842400 | Census Tract 8424 | 44 | 17031842400 | 44.0 | 8424 | None | POLYGON ((-87.62404799998049 41.73021699998396... |
1 | 17 | 031 | 840300 | Census Tract 8403 | 59 | 17031840300 | 59.0 | 8403 | None | POLYGON ((-87.6860799999848 41.82295600001154,... |
2 | 17 | 031 | 841100 | Census Tract 8411 | 34 | 17031841100 | 34.0 | 8411 | None | POLYGON ((-87.62934700001183 41.8527970000265,... |
3 | 17 | 031 | 841200 | Census Tract 8412 | 31 | 17031841200 | 31.0 | 8412 | None | POLYGON ((-87.68813499997718 41.85569099999095... |
4 | 17 | 031 | 838200 | Census Tract 8382 | 28 | 17031838200 | 28.0 | 8382 | None | POLYGON ((-87.66781999997529 41.8741839999791,... |