Code
i_g("bib/bdf/CNF2011-annexe1.png")
Data - INSEE
i_g("bib/bdf/CNF2011-annexe1.png")
%>%
t_7201 filter(date == as.Date("2018-12-31")) %>%
select(-date) %>%
mutate(value = round(value) %>% paste0(" Mds€")) %>%
if (is_html_output()) datatable(., filter = 'top', rownames = F) else .} {
%>%
t_7201 filter(variable %in% c("D11", "D1", "D12")) %>%
left_join(gdp, by = "date") %>%
ggplot(.) + theme_minimal() + ylab("Sociétés Financières (% du PIB)") + xlab("") +
geom_line(aes(x = date, y = value/gdp, color = Variable, linetype = Variable)) +
theme(legend.title = element_blank(),
legend.position = c(0.25, 0.9)) +
scale_x_date(breaks = seq(1950, 2020, 5) %>% paste0("-01-01") %>% as.Date,
limits = c(1949, 2020) %>% paste0("-01-01") %>% as.Date,
labels = date_format("%y")) +
scale_color_manual(values = viridis(4)[1:3]) +
scale_y_continuous(breaks = 0.01*seq(0, 100, 0.2),
labels = scales::percent_format(accuracy = .1))