Generates an animation based on COVID-19 daily data.
- Explanation: minutephysics: How To Tell If We're Beating COVID-19
- Data:
- Node 12.x
- Gulp:
npm install -g gulp
- Run:
npm install
- Clean:
gulp clean
- Build:
gulp build
node dist/main
The data is downloaded automatically
--help
(optional): Displays a help message and exits.--source
(optional): Sets the data source. Default:global
. Possible values:global
: Compare countriesus
: Compare states (US)chile
: Compare regions (Chile)
--schema
(optional): Sets the color schema. Default:dark
. Possible values:dark
: Dark theme
--layout
(optional): Sets the output layout. Default:vertical
. Possible values:square
: Square layout (1250x1250)vertical
: Vertical layout (1080x1920)horizontal
: Horizontal layout (1920x1080)
--days
(optional): Number of days for which the animation will be generated. Default: 20. Use 0 to plot all days.--frames
(optional): Number of frames per day. Default: 30.--extraFrames
(optional): Number of extra frames for the last image. Default: 300.
node dist/main
node dist/main --source global
node dist/main --layout square
node dist/main --source us --layout vertical
node dist/main --source us --layout vertical --frames 20
The generated images will be in the output
directory
You can generate an animation (60 fps). Requires ffmpeg. Run:
npm run video
The video will be here: output/animation.mp4