Exported from tbinenglanddataclean.

plot_historic_tb_ew(df = biddmodellingcourse::tb_not_ew,
  df_interventions = biddmodellingcourse::tb_interventions_timeline,
  zoom_date_start = 1982, zoom_date_end = NULL, plot_theme = NULL,
  colour_scale = NULL, return = FALSE)

Arguments

df

A dataframe, (defaults to using tb_not_ew) of historic TB notifications

df_interventions

A dataframe, (defaults to using tb_interventions_timeline) of TB interventions, focussing on there history in the UK. If passed as NULL no interventions will be plotted.

zoom_date_start

Numeric, the year to filter notifications from for the second zoomed plot.

zoom_date_end

Numeric, the year to end the zoom window, defaults to the final year of the data.

plot_theme

The ggplot2 theme to use, defaults to theme_minimal.

colour_scale

The colour scale to plot with, defaults to scale_colour_viridis_d

return

A logical indiciting if the plot should be printed or returned (defaults to FALSE)

Value

A ggplot2 plot of TB notifications over time, with a secondary zoomed plot from a specified date.

Examples

plot_historic_tb_ew()
#> Warning: Removed 284 rows containing missing values (geom_path).