Code Monkey home page Code Monkey logo

who-can-social-distance's Introduction

who-can-social-distance

This repository contains the code, visualizations, presentations, final paper for my Gonzaga University Honors college senior thesis which investigated the effects of socioeconomic and behavioral factors on the spread of COVID-19.

Some code is not included in this repository as it relied on private APIs or data repository that I was able to access from within Talus Analytics. Additionally, some code testing out different features and models has not been moved into the public repository yet.

Table of contents

Project goal

In creating this project, I tried to understand why the success of policy restrictions had varied so widely across the US. No two regions appeared to respond to stay at home orders the same. Whereas, one county might see case sky-rocket following the closure of indoor dining, another might see them gradually fall. I suspected that this had to to with the both the willingness and the ability of people to comply with mitigation policy.

Method

To test this hypothesis, I identifed a set of counties with similar policy restrictions using COVID-AMP. I then collected and combined a wide variety of data on that county's inhabitants including cell-phone mobility data, income, racial and ethnic identification, and teleworking ability. I then attempted to train a machine learning to predict the average caseload observed while the policy was in place given that information about the counties inhabitants.

I ultimately used a random forest algorithm.

random-forest

Results

To stop the model from using the time of year to estimate caseload, I split the larger dataset into a spring and fall dataset. On the spring dataset, the model was able to predict the number of COVID-19 cases observed while the policy was in place within an absolute mean error of 3.6 cases per 100,000 people, and the model was able to explain ~40-50% of the variance in the test set $(R^{2}=0.41, OOB = 0.48)$.

real-and-predicted

Race and household crowdedness were the two most important features in creating the final model prediction. feature-importance

From our exploratory data analysis, we know that those two features, like many of the features in our dataset are highly correlated, making it difficult to discern which was most important.

feature-heatmap

However, it seems likely that our model frequently relied on the racial makeup of a county in making its prediction in part because in the US race is highly correlated with access to healthcare, likelihood to be an essential worker, household crowdedness, and other factors that may affect COVID-19 outcomes.

For a more in-depth discussion of the process and results, the final presentation and paper that resulted from this project have been included in reports.

who-can-social-distance's People

Contributors

ciara-patterson avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.