draw_history: Create a plot of COVID-19, by count and by density of...

Description Usage Arguments Value

View source: R/graphics.R

Description

Create a plot of COVID-19, by count and by density of confirmed cases.

Usage

1
2
3
4
5
6
7
8
9
draw_history(
  x = read_datahub(state = "Maine"),
  pop = read_census(state = "Maine"),
  varname = "Confirmed",
  State_name = "",
  N = 1,
  threshold = c(10, NA)[1],
  logscale = TRUE
)

Arguments

x

tibble of COVID-19 and census data

pop

SF MUTLIPOLYGON table of county level geometry and population

varname

character, the name of the variable to draw ala 'Confirmed', 'Recovered', 'Deaths' etc.

State_name

character, for title, otherwise skip with ""

N

numeric, scaling for density. By default cases per 1000 people.

threshold

numeric, clip records (by county) where varname is less than this value. Set to NA to keep all.

logscale

logical, if TRUE then logscale the the dependent variables

Value

a ggplot object


BigelowLab/stcovid documentation built on May 1, 2020, 3:59 p.m.