All Projects → Kamaropoulos → COVID19Py

Kamaropoulos / COVID19Py

Licence: GPL-3.0 license
A tiny Python package for easy access to up-to-date Coronavirus (COVID-19, SARS-CoV-2) cases data.

Programming Languages

python
139335 projects - #7 most used programming language

Projects that are alternatives of or similar to COVID19Py

coronainfobd
Real-time corona-virus tracker of Bangladesh 🇧🇩 which includes latest updates, data visualization, public awareness from WHO and some advice to aware people. 🥰❤
Stars: ✭ 46 (-46.51%)
Mutual labels:  coronavirus, coronavirus-tracking, covid-19, covid19, covid19-data
COVID-19-DETECTION
Detect Covid-19 with Chest X-Ray Data
Stars: ✭ 43 (-50%)
Mutual labels:  coronavirus, coronavirus-tracking, covid-19, covid19, covid19-data
COVID19
A web app to display the live graphical state-wise reported corona cases in India so far. It also shows the latest news for COVID-19. Stay Home, Stay Safe!
Stars: ✭ 122 (+41.86%)
Mutual labels:  coronavirus, coronavirus-tracking, covid-19, covid19, covid19-data
covid19-visualized
COVID-19 World update with data Visualization (Include Indonesia cases)
Stars: ✭ 23 (-73.26%)
Mutual labels:  coronavirus, coronavirus-tracking, covid-19, covid19, covid19-data
covid-19
An app made with Flutter to track COVID-19 case counts.
Stars: ✭ 47 (-45.35%)
Mutual labels:  coronavirus, coronavirus-tracking, covid-19, covid19, covid19-data
COVID-19-Datasets
Novel Coronavirus (COVID-19) Cases for India, provided by University of Kalyani.
Stars: ✭ 19 (-77.91%)
Mutual labels:  coronavirus, coronavirus-tracking, covid-19, covid19, covid19-data
covidtrackerapiwrapper
CovidSharp is a crossplatform C# API wrapper for the Coronavirus tracking API (https://github.com/ExpDev07/coronavirus-tracker-api)
Stars: ✭ 11 (-87.21%)
Mutual labels:  api-wrapper, coronavirus, coronavirus-tracking, covid-19, covid19
coviddata
Daily COVID-19 statistics by country, region, and city
Stars: ✭ 49 (-43.02%)
Mutual labels:  coronavirus, coronavirus-tracking, covid-19, covid19, covid19-data
covid19-cli
A CLI for getting covid-19 coronavirus status of your district or state or country at lightning speed right on your terminal built using https://api.covid19india.org.
Stars: ✭ 19 (-77.91%)
Mutual labels:  coronavirus, coronavirus-tracking, covid19, covid19-data
covid-19-usa-by-state
CSV files of COVID-19 total daily confirmed cases and deaths in the USA by state and county. All data from Johns Hopkins & NYT..
Stars: ✭ 35 (-59.3%)
Mutual labels:  coronavirus, coronavirus-tracking, covid-19, covid19
covid19-timeseries
Covid19 timeseries data store
Stars: ✭ 38 (-55.81%)
Mutual labels:  coronavirus, covid-19, covid19, covid19-data
CoronaCord
Discord bot that displays the latest coronavirus statistics. Currently serving over 5,000 communities on Discord.
Stars: ✭ 23 (-73.26%)
Mutual labels:  coronavirus, coronavirus-tracking, covid19, covid19-data
covid-19-image-repository
Anonymized dataset of COVID-19 cases with a focus on radiological imaging. This includes images (x-ray / ct) with extensive metadata, such as admission-, ICU-, laboratory-, and patient master-data.
Stars: ✭ 42 (-51.16%)
Mutual labels:  coronavirus, covid-19, covid19, covid19-data
ctt
Corona Tracker Tracker Dashboard for the German Corona-Tracing-app
Stars: ✭ 15 (-82.56%)
Mutual labels:  coronavirus, coronavirus-tracking, covid19, covid19-data
covid19-kerala-api-deprecated
Deprecated - A fast API service for retrieving day to day stats about Coronavirus(COVID-19, SARS-CoV-2) outbreak in Kerala(India).
Stars: ✭ 14 (-83.72%)
Mutual labels:  coronavirus, coronavirus-tracking, covid19, covid19-data
covid19-pr-api
COVID-19 Open API for Datasets in Puerto Rico
Stars: ✭ 21 (-75.58%)
Mutual labels:  coronavirus, covid-19, covid19, covid19-data
Coronavirus
Java API Wrapper for tracking coronavirus (COVID-19, SARS-CoV-2) via https://git.io/Jvoep
Stars: ✭ 16 (-81.4%)
Mutual labels:  api-wrapper, coronavirus, covid-19, covid19
covid19-api
Covid19 Data API (JSON) - LIVE
Stars: ✭ 20 (-76.74%)
Mutual labels:  coronavirus, coronavirus-tracking, covid-19, covid19-data
Api
API for Current cases and more stuff about COVID-19 and Influenza
Stars: ✭ 2,323 (+2601.16%)
Mutual labels:  coronavirus, coronavirus-tracking, covid-19, covid19
coronavirus-data
This repository contains data on Coronavirus Disease 2019 (COVID-19) in New York City (NYC), from the NYC Department of Health and Mental Hygiene.
Stars: ✭ 926 (+976.74%)
Mutual labels:  coronavirus, covid-19, covid19, covid19-data

COVID19Py

Downloads Downloads Downloads GPLv3 License All Contributors CodeFactor HitCount GitHub stars

A tiny Python package for easy access to up-to-date Coronavirus (COVID-19, SARS-CoV-2) cases data.

About

COVID19Py is a Python wrapper made to be compatible with ExpDev07/coronavirus-tracker-api REST API. It retrieves data directly from an instance of @ExpDev07's backend but it can also be set up to use a different backend.

To achieve this, just pass the URL of the backend as a parameter to the library's constructor:

import COVID19Py
covid19 = COVID19Py.COVID19("https://my-awesome-covid19-backend")

Installation

In order install this package, simply run:

pip install COVID19Py

Usage

To use COVID19Py, you first need to import the package and then create a new instance:

import COVID19Py
covid19 = COVID19Py.COVID19()

Choosing a data source

COVID19Py supports the retrieval of data from multiple data sources. To choose a specific data source, simply pass it as a parameter to the library's constructor:

covid19 = COVID19Py.COVID19(data_source="csbs")

For more details about the available data sources, please check the API's documentation.

Getting latest amount of total confirmed cases, deaths, and recoveries:

latest = covid19.getLatest()

Getting all locations:

locations = covid19.getLocations()

or:

locations = covid19.getLocations(timelines=True)

to also get timelines.

You can also rank the results by confirmed, deaths or recovered.

locations = covid19.getLocations(rank_by='recovered')

Getting location by country code:

location = covid19.getLocationByCountryCode("US")

or:

location = covid19.getLocationByCountryCode("US", timelines=True)

to also get timelines.

Getting a specific location (includes timelines by default):

location = covid19.getLocationById(39)

Getting location by country name:

location = covid19.getLocationByCountry("Zimbabwe")

or:

location = covid19.getLocationByCountry("Zimbabwe", timelines=True)

Getting all data at once:

You can also get all the available data with one command.

data = covid19.getAll()

or:

data = covid19.getAll(timelines=True)

to also get timelines.

latest will be available on data["latest"] and locations will be available on data["locations"].

Getting latest deltas:

When using getAll(), COVID19Py will also store the previous version of the retrieved data. This allows us to easily see how data changed since the last time we requested them.

changes = covid19.getLatestChanges()
{
    "confirmed": 512,
    "deaths": 16,
    "recovered": 1024
}

Contributing

You will need to fork this repository onto your own GitHub account, then clone the repo to your local machine.

In the project directory, you will need to make sure the required packages are installed. To install requirements from the Pipfile, run a command like the following, which may depend on how you have package management set up:

pipenv install

Contributors

Thanks goes to these wonderful people (emoji key):


Konstantinos Kamaropoulos

💻 📖 💡

Jarod DeWeese

💻 📖

This project follows the all-contributors specification. Contributions of any kind welcome!

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].