Growth rate and growth acceleration calculation using COVID-19 data.
Typically, Anaconda distribution for Python >= 3.6 is enough.
The notebooks present an iterative and detailed calculation of growth rate, growth acceleration and growth acceleration rate for COVID-19 cases evolution.
growth_BR_states.ipynb
: Brazilian statesgrowth_BR_cities.ipynb
: Brazilian citiesgrowth_US_states.ipynb
: US statesgrowth_world.ipynb
: World countries.
Results: CSV files for the last available date in results/dfs
.
Script growth.py
performes computations detailed on the notebook via command line. It downloads update data to directory data
and outputs CSV files in results/dfs
.
--location
: Brazil, US, World.--state_or_city
: state, city (option available to Brazil).--slice
: set True to calculate for one specific location--slice_name
(IBGE code for cities).--not_last_date
: set True to check the result for an specific date (not the last one available) given by--date
.--output_name
: change the output file name. Default: output.csv--show_plot
: set True to show plots of growth rate, acceleration,acceleration rate and number of acculated cases.--save_figdata
: set True save plot data inresults/figures
.
Examples:
python growth.py --location Brazil --state_or_city state
python growth.py --location Brazil --state_or_city city
python growth.py --location US
python growth.py --location World
python growth.py --location Brazil --state_or_city city --slice True --slice_name=3550308
python growth.py --location Brazil --slice True --slice_name='RJ'
python growth.py --location World --slice True --slice_name='Germany'
python growth.py --location Brazil --state_or_city state --not_last_date True --date 2020-05-06
python growth.py --location Brazil --state_or_city state --output_name my_name.csv
python growth.py --location US --slice True --slice_name='New York' --show_plot True
python growth.py --location World --slice True --slice_name='South Korea' --show_plot True --save_figdata True