1.0.1 • Published 4 years ago

@karlbateman/covid-19 v1.0.1

Weekly downloads
3
License
MIT
Repository
-
Last release
4 years ago

COVID-19

GeoJSON data conversion for the JHU CSSE COVID-19 analysis

Build Status

Introduction

This project has been created to convert the daily JHU CSSE COVID-19 data into GeoJSON (RFC-7946) so that it can be easily plotted using mapping software, tools and libraries.

Prerequisites

Before proceeding to install this software, please ensure you have NodeJS and NPM installed on your system. I recommend you install these with NVM if you haven't done so already.

Getting Started

Follow the steps below to launch this tool locally:

  • Clone this project onto your machine
  • Change into the newly created directory
  • Install the projects dependencies npm install
  • Build the source files npm run build
  • Copy the example env config cp .env.example .env
  • Update the SOURCE_URL value
  • Run the tool npm start
  • You should have a covid-19.jsonl file

TIP Due to the report size the output file is formatted as JSON Lines for easier application consumption.

Example

Below is a sample from the generated output file.

{"type":"Feature","geometry":{"type":"Point","coordinates":[101,15]},"properties":{"province_or_state":"Not Provided","country_or_region":"Thailand","date":"2020-01-22","running_total_cases":"2","state_and_country":"Not Provided-Thailand","running_total_cases_prev_day":"0.0","daily_new_cases":"2.0","running_total_recoveries":"0","running_total_recoveries_prev_day":"0.0","daily_new_recoveries":"0.0","running_total_deaths":"0","running_total_deaths_prev_day":"0.0","daily_new_deaths":"0.0","state_name":"","first_case_state_rank":"","first_case_country_rank":"","country_code_2":"TH","country_code_3":"THA","country_population_2018":"69428524.0","country_median_age":"37.7","country_running_agg":"2","hundred_case_state_rank":"","hundred_case_country_rank":""}}
{"type":"Feature","geometry":{"type":"Point","coordinates":[101,15]},"properties":{"province_or_state":"Not Provided","country_or_region":"Thailand","date":"2020-01-23","running_total_cases":"3","state_and_country":"Not Provided-Thailand","running_total_cases_prev_day":"2.0","daily_new_cases":"1.0","running_total_recoveries":"0","running_total_recoveries_prev_day":"0.0","daily_new_recoveries":"0.0","running_total_deaths":"0","running_total_deaths_prev_day":"0.0","daily_new_deaths":"0.0","state_name":"","first_case_state_rank":"","first_case_country_rank":"","country_code_2":"TH","country_code_3":"THA","country_population_2018":"69428524.0","country_median_age":"37.7","country_running_agg":"3","hundred_case_state_rank":"","hundred_case_country_rank":""}}
{"type":"Feature","geometry":{"type":"Point","coordinates":[101,15]},"properties":{"province_or_state":"Not Provided","country_or_region":"Thailand","date":"2020-01-24","running_total_cases":"5","state_and_country":"Not Provided-Thailand","running_total_cases_prev_day":"3.0","daily_new_cases":"2.0","running_total_recoveries":"0","running_total_recoveries_prev_day":"0.0","daily_new_recoveries":"0.0","running_total_deaths":"0","running_total_deaths_prev_day":"0.0","daily_new_deaths":"0.0","state_name":"","first_case_state_rank":"1.0","first_case_country_rank":"1.0","country_code_2":"TH","country_code_3":"THA","country_population_2018":"69428524.0","country_median_age":"37.7","country_running_agg":"5","hundred_case_state_rank":"","hundred_case_country_rank":""}}
{"type":"Feature","geometry":{"type":"Point","coordinates":[101,15]},"properties":{"province_or_state":"Not Provided","country_or_region":"Thailand","date":"2020-01-25","running_total_cases":"7","state_and_country":"Not Provided-Thailand","running_total_cases_prev_day":"5.0","daily_new_cases":"2.0","running_total_recoveries":"0","running_total_recoveries_prev_day":"0.0","daily_new_recoveries":"0.0","running_total_deaths":"0","running_total_deaths_prev_day":"0.0","daily_new_deaths":"0.0","state_name":"","first_case_state_rank":"2.0","first_case_country_rank":"2.0","country_code_2":"TH","country_code_3":"THA","country_population_2018":"69428524.0","country_median_age":"37.7","country_running_agg":"7","hundred_case_state_rank":"","hundred_case_country_rank":""}}
{"type":"Feature","geometry":{"type":"Point","coordinates":[101,15]},"properties":{"province_or_state":"Not Provided","country_or_region":"Thailand","date":"2020-01-26","running_total_cases":"8","state_and_country":"Not Provided-Thailand","running_total_cases_prev_day":"7.0","daily_new_cases":"1.0","running_total_recoveries":"2","running_total_recoveries_prev_day":"0.0","daily_new_recoveries":"2.0","running_total_deaths":"0","running_total_deaths_prev_day":"0.0","daily_new_deaths":"0.0","state_name":"","first_case_state_rank":"3.0","first_case_country_rank":"3.0","country_code_2":"TH","country_code_3":"THA","country_population_2018":"69428524.0","country_median_age":"37.7","country_running_agg":"8","hundred_case_state_rank":"","hundred_case_country_rank":""}}

License

BSD © @karlbateman