p <- df %>%
pivot_longer(cols=c("puzzle_bigdave","puzzle_times"),
names_to="names",values_to="values")%>%
#count(year)
ggplot(aes(puzzle_date, fct_reorder(values,puzzle_date), color = values)) +
geom_jitter(show.legend = F,shape=".",color="white")+
geom_text(aes(label=answer),
size=9,
check_overlap = T,family="gbb")+
scale_color_manual(values=colors)+
labs(title = "\nSame Answers! Year: {closest_state}\nBigDave & Times puzzles\n",
subtitle="\nwords are randomized",
caption="#30DayChartChallenge 2022 #Day22\n DataSource: #TidyTuesday week16 - Crossword \n DataViz: Federica Gazzelloni\n\n")+
theme_void() +
theme(text = element_text(family = "ng", face="bold",color="#F0F8FF"),
plot.title = element_text(size=28),
plot.subtitle = element_text(size=18),
plot.caption = element_text(size=14,vjust=2,hjust=0.5),
plot.background = element_rect(fill="grey10",color="grey20"),
panel.background = element_rect(fill="grey10",color="grey20"),
legend.position = "none")+
coord_polar(theta = "x") +
transition_states(year,
transition_length = 2,
state_length = 1,
wrap = F) +
shadow_wake(wake_length = 0.5,wrap=F)
anim_save(animate(p,res=100,
renderer = gifski_renderer("animation3.gif"),
height = 710, width = 610))