demo_r_find3 %>%
filter(indic_de == "TOTFERRT",
nchar(geo) == 5,
time == "2018") %>%
select(geo, values) %>%
left_join(geo, by = "geo") %>%
right_join(europe_NUTS3, by = "geo") %>%
filter(long >= -15, lat >= 33, values <= 80000) %>%
ggplot(., aes(x = long, y = lat, group = group, fill = values)) +
geom_polygon() + coord_map() +
scale_fill_viridis_c(na.value = "white",
labels = scales::dollar_format(accuracy = .1, prefix = "", suffix = ""),
values = c(0, 0.05, 0.1, 0.15, 0.2, 0.3, 0.4, 0.5, 1),
breaks = seq(0, 4, 0.5),
direction = -1) +
theme_void() + theme(legend.position = c(0.25, 0.85)) +
labs(fill = "Fertility Rate")