Plot a Time Series with Confidence.

plot_confidence(
  data,
  outer_alpha = 0.1,
  inner_alpha = 0.2,
  plot_median = TRUE,
  legend = "none"
)

Arguments

data

Dataframe containing the follwoing variables: date, median, type, bottom, top, lower, upper, and confidence

outer_alpha

Numeric, outer alpha level.

inner_alpha

Numeric, inner alpha level.

plot_median

Logical, defaults to FALSE. Should the median be plotted.

legend

Character string defaults to "none". Should a legend be displayed.

Value

A ggplot2 object.