
Navigate to coronavirus-project.dunderdata.com to view the live dashboard!
Update!
Step 7 has changed since the video was created. Make sure to use the step below in the text!
Create the virtual environment quickly. Use the next video for a more detailed explanation.
cd into the project directory
python -m venv dashboard_venv
source dashboard_venv/bin/activate
pip install -U pip
pip install wheel
pip install -r requirements.txt
pip install matplotlib==3.4.3 nbconvert==5.6.1 notebook==6.1.6
pip install jupyter-dash==0.4
Note for windows users - Activate your virtual environment by running the command dashboard_venv\Scripts\activate.bat. Do not use source as shown in the video.
Update!
Step 7 has changed since the video was created. Make sure to use the step below in the text!
cd into the project directory
python -m venv dashboard_venv
source dashboard_venv/bin/activate
pip install -U pip
pip install wheel
pip install -r requirements.txt
pip install matplotlib==3.4.3 nbconvert==5.6.1 notebook==6.1.6
pip install jupyter-dash==0.4
Note for windows users - Activate your virtual environment by running the command dashboard_venv\Scripts\activate.bat. Do not use source as shown in the video.
Activate and deactivate the virtual environment to control Python mappings and libraries, using the deactivate command or the bin activate script, and optionally reactivating the conda environment for consistent dashboard.
Launch the Dash dashboard by activating the virtual env and running python dashboard.py, then explore world and U.S. data, interactive tables, charts, maps, and hover details, with stop via Ctrl-C.
Open the Jupyter notebooks by activating the virtual environment in the project directory and launching Jupyter Notebook from the course’s notebooks folder to run the dashboard code.
Transpose the data to move dates into rows and countries into columns, creating a time series with a date time index using pandas.
Encapsulate all data cleaning and transformation steps into a single prepare data class, with an option to download new data or read local data, producing four prepared data frames.
Explore exponential growth and decline using a × b^x, where a is the initial value, b the growth rate, and x the time unit; b>1 grows, b<1 declines toward zero.
Automate model training by wrapping least squares optimization into a reusable function that fits a simple exponential model to any data series with given bounds and an initial guess.
Model exponential decline in coronavirus curves, introducing increasing exponential decline with a shift parameter to keep values positive; compare with growth using Italy data and note the upcoming logistic model.
Explore asymptotes in logistic growth models and how they differ from exponential curves, using the coronavirus cumulative curve and 1/x, a/(b+x^2) to illustrate limits.
Smooth Italy case data, fit a logistic model by least-squares to estimate L, x0, and K within defined bounds, and project future cases up to May 1 using the model.
Discover why detecting wave starts is unnecessary; the model shifts vertically and horizontally to align with wave, from Italy, United Kingdom, and New York state data toward logistic asymptote.
Predict deaths by estimating the case fatality ratio from lagged cases, using a 50 day lag and 30 day windows to compute CFR for US and world.
The deaths model class computes a CFR per area using lag and period, then predicts future deaths by multiplying cases from past dates by that CFR, followed by smoothing.
Instantiate and run the deaths model with training data to generate daily and cumulative death predictions for the first 10 states, and view a 30-day forecast with a 15-day lag.
Explore update.py, which runs all course data analysis to update two CSV files—one for all data and one for the summary—via the command line with an optional last-date argument.
Learn to automate plotting for a specific area by filtering a data frame, selecting a kind, and producing a bar plot of actual versus predicted values over time.
learn to add customized subplot titles using annotations in a plotting workflow, employing update layout to label cases and deaths and customize legend placement.
Learn to build interactive data visualizations with Plotly by creating figures with go.Figure or subplots, adding traces, and updating the layout, including geo maps with polygon data.
This course teaches you all of the skills to build interactive data analytics dashboards with Python. Specifically, you will be building a Coronavirus Forecasting Dashboard that shows historical and predicted values for deaths and cases for all countries in the world and US states from the ongoing coronavirus pandemic. The final product will be a live dashboard, automatically updated daily, hosted on a remote server for anyone, anywhere in the world to see!
You will learn and complete the entire process for building the dashboard including the following topics:
Getting, Cleaning, and Transforming the Data - You will learn how to collect the data, find and clean bad data, and transform it so that it can be used for building models capable of prediction.
Data Smoothing - You will learn several different techniques such as LOWESS to smooth the jagged raw data so that the model can better detect trends.
Exponential Growth and Decline Models - You will begin modeling coronavirus cases for each area of the world with these simple models that can capture a single exponential growth or decline phase, but not both.
Logistic Growth Models - You will learn about a separate class of "S-Curve" models capable of capturing both exponential growth and decline in the same model.
Modeling New Waves - Coronavirus cases appear in waves over different time periods. You will learn how to change your model so that it can detect any number of new waves in the future.
Encapsulation into Classes - After selecting your model, you will encapsulate all of the code together into Python classes, eventually to be used in your final production code.
Visualizations with Plotly - You will learn how to use the Plotly Python library to create interactive data visualizations targeted for the web
HTML and CSS - You are building a web application and will learn the fundamentals of HTML and CSS to help add customization with the help of Dash.
Building the Dashboard with Dash - You will learn how to build all of the components and interactivity of the dashboard with the Dash Python library.
Deployment - One of the most exciting parts of a project is deploying it on your own server for the world to see. You will learn two different deployment options - one simple and the other more complex, but with more flexibility.
What's Included?
This course comes with a massive amount of material including:
13 Jupyter Notebooks
26 Exercises with detailed solutions
200 page PDF of the entire course content
All production code for the dashboard
Technologies used
All code for developing the dashboard will be done using Python
Pandas will be used extensively for analyzing and transforming data
Statsmodels will be used for smoothing
Scipy will be used for building the models for coronavirus cases and parameter optimization
Matplotlib will be used in the notebooks for static visualizations
Plotly will be used for interactive data visualizations that appear in the dashboard
Dash will be used for building the dashboard itself
HTML/CSS will be used together with Dash to customize components of the dashboard
You'll learn how to setup your own Linux Ubuntu server to run your dashboard