1 min readMay 22, 2020
I am going through it, but get an error at the first ggplot:
> d <- y['global'] # extract global data
> d <- d[d$country != 'China',] # exclude China
> n <- d %>% filter(time == time(y)) %>%
+ top_n(10, cum_confirm) %>%
+ arrange(desc(cum_confirm)) # plot top 10
> ggplot(filter(d, country %in% n$country, d$time > '2020–02–15'),
+ aes(time, cum_confirm, color=country)) +
+ geom_line() +
+ geom_text_repel(aes(label=country),
+ function(d) d[d$time == time(y),]) +
+ theme_minimal(base_size=14) +
+ theme(legend.position = 'none')
Error in charToDate(x) :
character string is not in a standard unambiguous format