Giter VIP home page Giter VIP logo

covid-project's Introduction

Project Overview

This project was inspired by Alex The Analyst and his Covid Analysis. The goal of this project is to demonstrate how to connect a PostgreSQL database to Python and run queries through it, using the Python libraries Pandas and Psycopg2. The project also includes a Jupyter notebook that shows a step-by-step process for extracting and analyzing historical data of COVID-19 up to January 8, 2022.

Project Outline

  1. Data Preparation: We first used Microsoft Excel to format and modify a .csv file downloaded from Our World In Data into two separate files ("CovidDeaths.csv" and "CovidVaccinations.csv"), which were then uploaded to a local PostgreSQL database.
  2. Connect to Database: Next, we used the Python library Psycopg2 to connect to the PostgreSQL database and run SQL queries to extract the data we needed.
  3. Create Views: We also saved some of the queries as views, which were not used in this project, but can be helpful for other projects.
  4. Data Analysis: Finally, we used the Pandas library to display the results of the queries, perform further analysis and manipulate the data for better understanding.

Project Goal

The main goal of this project is to extract insights and deliver a interactive visualization to showcase the analysis on historical data of COVID-19, up to the date Jan 8, 2022. The project also demonstrates how to integrate Postgres SQL with Python to run queries, and use libraries like Pandas for analysis and data manipulation

Sample Code

Connecting to PostgreSQL Database

sample_query1

Create views and display with Pandas

sample_query sample_results

Conclusion

This project serves as a useful resource for anyone looking to connect a PostgreSQL database to Python and run queries through it, as well as for those looking to use Pandas for data analysis and manipulation.

You can find the code for this project on HERE

covid-project's People

Contributors

laidbackluck 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.