ggplot(dat, aes(x = year_quarter, y = percent_positive)) +
geom_bar(stat = "identity") +
labs(x = "Year and quarter", y = "% positive", title = "% positivity by quarter") +
theme_minimal()+
scale_x_yearqtr(format = "%Y-Q%q", n=9)+ # makes the format and number of axis labels)
theme(axis.text.x = element_text(angle = 35, hjust = 1)) # sets angle of labels