plot1: Make a plot of positives, active and recovered versus time

Description Usage Arguments Examples

View source: R/plot1.R

Description

Makes a plot of positives, active and recovered versus time. New cases per day is added as a line. If lockdown date is given, a line is added showing that. Plot is shown for a specific region (state, country, province, etc). Use regions() to see what locations are available. See ?getdatajhu, ?getdataitaly, ?getdatastates to see the data sources.

Usage

1
plot1(data = c("states", "world", "italy"), region, lockdown = NULL)

Arguments

data

Name of a data set. "states", "world" or "italy"

region

Name of a region in the region (location) column of the dataset (dataset$region). Might be country, state, or province. Use regions() to see what is available.

lockdown

(optional) Date of the lockdown in "2020-03-11" format.

Examples

1
2
plot1(data="italy", region="Lombardia", lockdown="2020-03-11")
plot1(data="states", region="NY", lockdown="2020-03-21")

eeholmes/CoV19 documentation built on Oct. 19, 2021, 10:59 a.m.