Demographic Factors Behind the Covid-19 Crisis in NYC

Posted on May 18, 2020
The skills I demoed here can be learned through taking Data Science with Machine Learning bootcamp with NYC Data Science Academy.

Github/Shiny App/LinkedIn


In building this app I wanted to create a visualization and demographic of the Covid-19 crisis in NYC. NYC quickly became the global epicenter of the virus with over 193,00 cases recorded currently and over 15,000 deaths. Many attribute this to NYC behind an exceptionally dense city with a robust public transportation system.

However, when we look at places like Singapore, the 3rd densest country on earth, we see a much lower infection rate of 28,000 people and only 22 deaths. I decided to explore the social and economic inequalities present in NYC to determine if I could find a more robust correlation to infection rates than density alone.

First Shiny Slide: Density.

By examining recent census data and Covid-19 testing data by zip code made available to me by the NYC Health Department I was able to compare different demographics to the Covid-19 outbreak severity in NYC. As I suspected there was no correlation between density and the infection rates across NYC zip codes. 

Second Shiny Slide: Interactive Demographic Data

In this section of the app, I built an interactive plot with the options to plot different demographic features (percent taking public transit, percent with a bachelor's degree or higher, percent living in crowded housing, and median household income) for the population of each zip code and different COVID-19 infection statistics (percent of the tested population that is positive, Total Positive, Total Tests). 

These plots show that there was no correlation between infection rates and the percent of the population taking public transit to work. However, the transit data was taken before the crisis, so it does not reflect transit activity during the outbreak as those who are not essential workers are no longer traveling to work (which is best illustrated by demographic divides). Infection rates by zip code showed a significant inverse correlation with Median Income and Percent of the population with a college degree.

Similarly, there was a significant direct correlation between infection rates and the percent of the population living in crowded housing (which I defined as families of 5 or more or nonfamilies of 4 or more living together). The correlation coefficients for these features were -0.68, -0.83, and 0.74 respectively.

Choropleth Maps:

In another slide, this data is also visualized in 3 choropleth maps that show the virus hotspots as well as the distribution of economic resources and housing. by looking at the maps you can see that the outbreak hotspots are in the same locations where income is the lowest and housing is the most crowded.


My data analysis has shown that density is not the driving factor of the severity of the outbreak in NYC, but that a lack of access to economic opportunity, education, and adequate housing are! Simply put, not everyone can afford to socially distance. If you do not hold a college degree you are likely to be working an essential job that you cannot afford to take off from, which puts you and your family directly in the line of fire of the pandemic. Likewise, you cannot be socially distant if you live in tight quarters with several roommates or at-risk family members.

Coupled with the fact that individuals with these risk factors are likely to live in the same area, which compounds the risk. In order to fully address this pandemic and lessen the severity of future pandemics, I recommend an overhaul in housing, educational, and economic infrastructure to address this issue.

Further investigations would include a comparison between infection rates and access to healthcare in the city as well as tracking the severity throughout public housing and nursing homes. I would also like to compare the demographics and severity of the crisis to other similarly dense cities either in the US or elsewhere. 

Data Credit: Steven Manson, Jonathan Schroeder, David Van Riper, and Steven Ruggles. IPUMS National Historical Geographic Information System: Version 14.0 [Database]. Minneapolis, MN: IPUMS. 2019.


About Author

David Zask

Certified data scientist with extensive project experience. Skilled in Machine Learning, Big Data, Unsupervised Learning, Deep Learning, Data Engineering, R, Python, Documentation, Data Analytics, Start-ups, and Business Development. Strong data science and media professional with a BA in...
View all posts by David Zask >

Leave a Comment

No comments found.

View Posts by Categories

Our Recent Popular Posts

View Posts by Tags

#python #trainwithnycdsa 2019 2020 Revenue 3-points agriculture air quality airbnb airline alcohol Alex Baransky algorithm alumni Alumni Interview Alumni Reviews Alumni Spotlight alumni story Alumnus ames dataset ames housing dataset apartment rent API Application artist aws bank loans beautiful soup Best Bootcamp Best Data Science 2019 Best Data Science Bootcamp Best Data Science Bootcamp 2020 Best Ranked Big Data Book Launch Book-Signing bootcamp Bootcamp Alumni Bootcamp Prep boston safety Bundles cake recipe California Cancer Research capstone car price Career Career Day citibike classic cars classpass clustering Coding Course Demo Course Report covid 19 credit credit card crime frequency crops D3.js data data analysis Data Analyst data analytics data for tripadvisor reviews data science Data Science Academy Data Science Bootcamp Data science jobs Data Science Reviews Data Scientist Data Scientist Jobs data visualization database Deep Learning Demo Day Discount disney dplyr drug data e-commerce economy employee employee burnout employer networking environment feature engineering Finance Financial Data Science fitness studio Flask flight delay gbm Get Hired ggplot2 googleVis H20 Hadoop hallmark holiday movie happiness healthcare frauds higgs boson Hiring hiring partner events Hiring Partners hotels housing housing data housing predictions housing price hy-vee Income Industry Experts Injuries Instructor Blog Instructor Interview insurance italki Job Job Placement Jobs Jon Krohn JP Morgan Chase Kaggle Kickstarter las vegas airport lasso regression Lead Data Scienctist Lead Data Scientist leaflet league linear regression Logistic Regression machine learning Maps market matplotlib Medical Research Meet the team meetup methal health miami beach movie music Napoli NBA netflix Networking neural network Neural networks New Courses NHL nlp NYC NYC Data Science nyc data science academy NYC Open Data nyc property NYCDSA NYCDSA Alumni Online Online Bootcamp Online Training Open Data painter pandas Part-time performance phoenix pollutants Portfolio Development precision measurement prediction Prework Programming public safety PwC python Python Data Analysis python machine learning python scrapy python web scraping python webscraping Python Workshop R R Data Analysis R language R Programming R Shiny r studio R Visualization R Workshop R-bloggers random forest Ranking recommendation recommendation system regression Remote remote data science bootcamp Scrapy scrapy visualization seaborn seafood type Selenium sentiment analysis sentiment classification Shiny Shiny Dashboard Spark Special Special Summer Sports statistics streaming Student Interview Student Showcase SVM Switchup Tableau teachers team team performance TensorFlow Testimonial tf-idf Top Data Science Bootcamp Top manufacturing companies Transfers tweets twitter videos visualization wallstreet wallstreetbets web scraping Weekend Course What to expect whiskey whiskeyadvocate wildfire word cloud word2vec XGBoost yelp youtube trending ZORI