Open
Description
Forecasters may have multiple forecasts for the same week end date with the same score, and tsibbles need unique keys/indexes. Simply removing dups before setting the tsibble (something like this: filteredScoreDf = filteredScoreDf[!duplicated(filteredScoreDf[c("Week_End_Date" , "Forecaster")]), ]
) will mess up how the faceted plots work.
Right now this is only happening with the CU-select forecaster. It doesn't show a plot for US deaths bc it contains week end date / score dups.
Tsibble code:
# Fill gaps so there are line breaks on weeks without data
filteredScoreDf = filteredScoreDf %>%
as_tsibble(key = c(Forecaster, ahead), index = Week_End_Date) %>%
group_by(Forecaster, Forecast_Date, ahead) %>%
fill_gaps(.full = TRUE)