SHA %>%
left_join(SHA_var$HF, by = "HF") %>%
group_by(HF, Hf) %>%
summarise(Nobs = n()) %>%
arrange(-Nobs) %>%
print_table_conditional()
HF | Hf | Nobs |
---|---|---|
HFTOT | All financing schemes | 2102835 |
HF1 | Government/compulsory schemes | 544719 |
HF2HF3 | Voluntary schemes/household out-of-pocket payments | 450722 |
HF11 | Government schemes | 410559 |
HF3 | Household out-of-pocket payments | 351674 |
HF12HF13 | Compulsory contributory health insurance schemes | 327551 |
HF2 | Voluntary health care payment schemes | 320875 |
HF121 | Social health insurance schemes | 246188 |
HF21 | Voluntary health insurance schemes | 241386 |
HF22 | NPISH financing schemes | 122707 |
HF31 | Out-of-pocket excluding cost-sharing | 119141 |
HF23 | Enterprise financing schemes | 100645 |
HF32 | Cost-sharing with third-party payers | 95846 |
HF122 | Compulsory private insurance schemes | 71370 |
HF4 | Rest of the world financing schemes (non-resident) | 14388 |
HF0 | Financing schemes unknown | 380 |
SHA %>%
left_join(SHA_var$MEASURE, by = "MEASURE") %>%
group_by(MEASURE, Measure) %>%
summarise(Nobs = n()) %>%
arrange(-Nobs) %>%
print_table_conditional()
MEASURE | Measure | Nobs |
---|---|---|
MLLNCU | Current prices | 450244 |
MTMOPP | Current prices, current PPPs | 448707 |
UNPPER | Per capita, current prices | 448273 |
VALREL | Constant prices, OECD base year | 446598 |
PPPPER | Per capita, current prices, current PPPs | 446550 |
VRPPPT | Constant prices, constant PPPs, OECD base year | 446314 |
REPPER | Per capita, constant prices, OECD base year | 445080 |
VRPPPR | Per capita, constant prices, constant PPPs, OECD base year | 444367 |
PARCUR | Share of current expenditure on health | 421779 |
PARPIB | Share of gross domestic product | 413258 |
PARHP | Share of provider | 372806 |
PARHC | Share of function | 371479 |
PARHF | Share of financing scheme | 365531 |
SHA %>%
left_join(SHA_var$LOCATION, by = "LOCATION") %>%
group_by(LOCATION, Location) %>%
summarise(Nobs = n()) %>%
arrange(-Nobs) %>%
mutate(Flag = gsub(" ", "-", str_to_lower(Location)),
Flag = paste0('<img src="../../icon/flag/vsmall/', Flag, '.png" alt="Flag">')) %>%
select(Flag, everything()) %>%
{if (is_html_output()) datatable(., filter = 'top', rownames = F, escape = F) else .}
SHA %>%
filter(MEASURE == "PARPIB",
HP == "HPTOT",
HC == "HCTOT",
LOCATION %in% c("FRA", "DEU", "ITA")) %>%
left_join(SHA_var$HF, by = "HF") %>%
group_by(LOCATION, HF, Hf) %>%
summarise(value = last(obsValue)) %>%
spread(LOCATION, value) %>%
print_table_conditional()
HF | Hf | DEU | FRA | ITA |
---|---|---|---|---|
HF1 | Government/compulsory schemes | 10.665 | 9.302 | 7.412 |
HF11 | Government schemes | 0.764 | 0.612 | 7.395 |
HF121 | Social health insurance schemes | 8.292 | 7.938 | 0.016 |
HF122 | Compulsory private insurance schemes | 0.841 | 0.751 | NA |
HF12HF13 | Compulsory contributory health insurance schemes | 9.132 | 8.689 | 0.016 |
HF2 | Voluntary health care payment schemes | 0.323 | 0.781 | 0.252 |
HF21 | Voluntary health insurance schemes | 0.163 | 0.712 | 0.191 |
HF22 | NPISH financing schemes | 0.105 | 0.001 | 0.020 |
HF23 | Enterprise financing schemes | 0.048 | 0.069 | 0.040 |
HF2HF3 | Voluntary schemes/household out-of-pocket payments | 1.865 | 1.810 | 2.304 |
HF3 | Household out-of-pocket payments | 1.542 | 1.029 | 2.053 |
HF31 | Out-of-pocket excluding cost-sharing | NA | 0.530 | NA |
HF32 | Cost-sharing with third-party payers | NA | 0.499 | NA |
HFTOT | All financing schemes | 12.530 | 12.377 | 9.716 |
SHA %>%
filter(HC == "HCTOT",
MEASURE == "PARPIB",
HP == "HPTOT",
HF == "HFTOT",
LOCATION %in% c("FRA", "DEU", "ITA")) %>%
left_join(SHA_var$LOCATION, by = "LOCATION") %>%
year_to_date %>%
left_join(colors, by = c("Location" = "country")) %>%
mutate(obsValue = obsValue/100) %>%
ggplot() + geom_line(aes(x = date, y = obsValue, color = color)) +
scale_color_identity() + theme_minimal() + add_3flags +
scale_x_date(breaks = seq(1920, 2025, 5) %>% paste0("-01-01") %>% as.Date,
labels = date_format("%y")) +
scale_y_continuous(breaks = 0.01*seq(-7, 60, 1),
labels = scales::percent_format(accuracy = 1)) +
ylab("% of GDP") + xlab("")
SHA %>%
filter(HC == "HCTOT",
MEASURE == "PARPIB",
HP == "HPTOT",
HF == "HF1",
LOCATION %in% c("FRA", "DEU", "ITA")) %>%
left_join(SHA_var$LOCATION, by = "LOCATION") %>%
year_to_date %>%
left_join(colors, by = c("Location" = "country")) %>%
mutate(obsValue = obsValue/100) %>%
ggplot() + geom_line(aes(x = date, y = obsValue, color = color)) +
scale_color_identity() + theme_minimal() + add_3flags +
scale_x_date(breaks = seq(1920, 2025, 5) %>% paste0("-01-01") %>% as.Date,
labels = date_format("%y")) +
scale_y_continuous(breaks = 0.01*seq(-7, 60, 1),
labels = scales::percent_format(accuracy = 1)) +
ylab("% of GDP") + xlab("")
SHA %>%
filter(HC == "HCTOT",
MEASURE == "PARPIB",
HP == "HPTOT",
HF == "HF11",
LOCATION %in% c("FRA", "DEU", "ITA")) %>%
left_join(SHA_var$LOCATION, by = "LOCATION") %>%
year_to_date %>%
left_join(colors, by = c("Location" = "country")) %>%
mutate(obsValue = obsValue/100) %>%
ggplot() + geom_line(aes(x = date, y = obsValue, color = color)) +
scale_color_identity() + theme_minimal() + add_3flags +
scale_x_date(breaks = seq(1920, 2025, 5) %>% paste0("-01-01") %>% as.Date,
labels = date_format("%y")) +
scale_y_continuous(breaks = 0.01*seq(-7, 60, 1),
labels = scales::percent_format(accuracy = 1)) +
ylab("% of GDP") + xlab("")
SHA %>%
filter(HC == "HCTOT",
MEASURE == "PARPIB",
HP == "HPTOT",
HF == "HF121",
LOCATION %in% c("FRA", "DEU", "ITA")) %>%
left_join(SHA_var$LOCATION, by = "LOCATION") %>%
year_to_date %>%
left_join(colors, by = c("Location" = "country")) %>%
mutate(obsValue = obsValue/100) %>%
ggplot() + geom_line(aes(x = date, y = obsValue, color = color)) +
scale_color_identity() + theme_minimal() + add_3flags +
scale_x_date(breaks = seq(1920, 2025, 5) %>% paste0("-01-01") %>% as.Date,
labels = date_format("%y")) +
scale_y_continuous(breaks = 0.01*seq(-7, 60, 1),
labels = scales::percent_format(accuracy = 1)) +
ylab("% of GDP") + xlab("")
SHA %>%
filter(HC == "HCTOT",
MEASURE == "PARPIB",
HP == "HPTOT",
HF == "HF122",
LOCATION %in% c("FRA", "DEU", "ITA")) %>%
left_join(SHA_var$LOCATION, by = "LOCATION") %>%
year_to_date %>%
left_join(colors, by = c("Location" = "country")) %>%
mutate(obsValue = obsValue/100) %>%
ggplot() + geom_line(aes(x = date, y = obsValue, color = color)) +
scale_color_identity() + theme_minimal() + add_3flags +
scale_x_date(breaks = seq(1920, 2025, 5) %>% paste0("-01-01") %>% as.Date,
labels = date_format("%y")) +
scale_y_continuous(breaks = 0.01*seq(-7, 60, .1),
labels = scales::percent_format(accuracy = .1)) +
ylab("% of GDP") + xlab("")
SHA %>%
filter(HC == "HCTOT",
MEASURE == "PARPIB",
HP == "HPTOT",
HF == "HF2HF3",
LOCATION %in% c("FRA", "DEU", "ITA")) %>%
left_join(SHA_var$LOCATION, by = "LOCATION") %>%
year_to_date %>%
left_join(colors, by = c("Location" = "country")) %>%
mutate(obsValue = obsValue/100) %>%
ggplot() + geom_line(aes(x = date, y = obsValue, color = color)) +
scale_color_identity() + theme_minimal() + add_3flags +
scale_x_date(breaks = seq(1920, 2025, 5) %>% paste0("-01-01") %>% as.Date,
labels = date_format("%y")) +
scale_y_continuous(breaks = 0.01*seq(-7, 60, 0.2),
labels = scales::percent_format(accuracy = .1)) +
ylab("% of GDP") + xlab("")
SHA %>%
filter(HC == "HCTOT",
MEASURE == "PARPIB",
HP == "HPTOT",
HF == "HF2",
LOCATION %in% c("FRA", "DEU", "ITA")) %>%
left_join(SHA_var$LOCATION, by = "LOCATION") %>%
year_to_date %>%
left_join(colors, by = c("Location" = "country")) %>%
mutate(obsValue = obsValue/100) %>%
ggplot() + geom_line(aes(x = date, y = obsValue, color = color)) +
scale_color_identity() + theme_minimal() + add_3flags +
scale_x_date(breaks = seq(1920, 2025, 5) %>% paste0("-01-01") %>% as.Date,
labels = date_format("%y")) +
scale_y_continuous(breaks = 0.01*seq(-7, 60, 0.2),
labels = scales::percent_format(accuracy = .1)) +
ylab("% of GDP") + xlab("")
SHA %>%
filter(HC == "HCTOT",
MEASURE == "PARPIB",
HP == "HPTOT",
HF == "HF21",
LOCATION %in% c("FRA", "DEU", "ITA")) %>%
left_join(SHA_var$LOCATION, by = "LOCATION") %>%
year_to_date %>%
left_join(colors, by = c("Location" = "country")) %>%
mutate(obsValue = obsValue/100) %>%
ggplot() + geom_line(aes(x = date, y = obsValue, color = color)) +
scale_color_identity() + theme_minimal() + add_3flags +
scale_x_date(breaks = seq(1920, 2025, 5) %>% paste0("-01-01") %>% as.Date,
labels = date_format("%y")) +
scale_y_continuous(breaks = 0.01*seq(-7, 60, 0.2),
labels = scales::percent_format(accuracy = .1)) +
ylab("% of GDP") + xlab("")
SHA %>%
filter(HC == "HCTOT",
MEASURE == "PARPIB",
HP == "HPTOT",
HF == "HF22",
LOCATION %in% c("FRA", "DEU", "ITA")) %>%
left_join(SHA_var$LOCATION, by = "LOCATION") %>%
year_to_date %>%
left_join(colors, by = c("Location" = "country")) %>%
mutate(obsValue = obsValue/100) %>%
ggplot() + geom_line(aes(x = date, y = obsValue, color = color)) +
scale_color_identity() + theme_minimal() + add_3flags +
scale_x_date(breaks = seq(1920, 2025, 5) %>% paste0("-01-01") %>% as.Date,
labels = date_format("%y")) +
scale_y_continuous(breaks = 0.01*seq(-7, 60, 0.01),
labels = scales::percent_format(accuracy = .01)) +
ylab("% of GDP") + xlab("")
SHA %>%
filter(HC == "HCTOT",
MEASURE == "PARPIB",
HP == "HPTOT",
HF == "HF23",
LOCATION %in% c("FRA", "DEU", "ITA")) %>%
left_join(SHA_var$LOCATION, by = "LOCATION") %>%
year_to_date %>%
left_join(colors, by = c("Location" = "country")) %>%
mutate(obsValue = obsValue/100) %>%
ggplot() + geom_line(aes(x = date, y = obsValue, color = color)) +
scale_color_identity() + theme_minimal() + add_3flags +
scale_x_date(breaks = seq(1920, 2025, 5) %>% paste0("-01-01") %>% as.Date,
labels = date_format("%y")) +
scale_y_continuous(breaks = 0.01*seq(-7, 60, 0.01),
labels = scales::percent_format(accuracy = .01)) +
ylab("% of GDP") + xlab("")
SHA %>%
filter(HC == "HCTOT",
MEASURE == "PARPIB",
HP == "HPTOT",
HF == "HF3",
LOCATION %in% c("FRA", "DEU", "ITA")) %>%
left_join(SHA_var$LOCATION, by = "LOCATION") %>%
year_to_date %>%
left_join(colors, by = c("Location" = "country")) %>%
mutate(obsValue = obsValue/100) %>%
ggplot() + geom_line(aes(x = date, y = obsValue, color = color)) +
scale_color_identity() + theme_minimal() + add_3flags +
scale_x_date(breaks = seq(1920, 2025, 5) %>% paste0("-01-01") %>% as.Date,
labels = date_format("%y")) +
scale_y_continuous(breaks = 0.01*seq(-7, 60, 0.2),
labels = scales::percent_format(accuracy = .1)) +
ylab("% of GDP") + xlab("")
SHA %>%
filter(HC == "HCTOT",
MEASURE == "PARPIB",
HP == "HPTOT",
HF == "HF31",
LOCATION %in% c("FRA", "DEU", "ITA")) %>%
left_join(SHA_var$LOCATION, by = "LOCATION") %>%
year_to_date %>%
left_join(colors, by = c("Location" = "country")) %>%
mutate(obsValue = obsValue/100) %>%
ggplot() + geom_line(aes(x = date, y = obsValue, color = color)) +
scale_color_identity() + theme_minimal() + add_3flags +
scale_x_date(breaks = seq(1920, 2025, 1) %>% paste0("-01-01") %>% as.Date,
labels = date_format("%y")) +
scale_y_continuous(breaks = 0.01*seq(-7, 60, 0.01),
labels = scales::percent_format(accuracy = .01)) +
ylab("% of GDP") + xlab("")
SHA %>%
filter(HC == "HCTOT",
MEASURE == "PARPIB",
HP == "HPTOT",
HF == "HF32",
LOCATION %in% c("FRA", "DEU", "ITA")) %>%
left_join(SHA_var$LOCATION, by = "LOCATION") %>%
year_to_date %>%
left_join(colors, by = c("Location" = "country")) %>%
mutate(obsValue = obsValue/100) %>%
ggplot() + geom_line(aes(x = date, y = obsValue, color = color)) +
scale_color_identity() + theme_minimal() + add_3flags +
scale_x_date(breaks = seq(1920, 2025, 1) %>% paste0("-01-01") %>% as.Date,
labels = date_format("%y")) +
scale_y_continuous(breaks = 0.01*seq(-7, 60, 0.01),
labels = scales::percent_format(accuracy = .01)) +
ylab("% of GDP") + xlab("")
SHA %>%
filter(HC == "HC6",
MEASURE == "PARPIB",
HP == "HPTOT",
HF == "HFTOT") %>%
left_join(SHA_var$LOCATION, by = "LOCATION") %>%
group_by(LOCATION, Location) %>%
summarise(Nobs = n(),
`Year 1` = first(obsTime),
`Preventive Care 1` = first(obsValue),
`Year 2` = last(obsTime),
`Preventive Care 2` = last(obsValue)) %>%
arrange(-`Preventive Care 2`) %>%
print_table_conditional()
SHA %>%
filter(HC == "HC6",
MEASURE == "PARPIB",
HP == "HPTOT",
HF == "HFTOT",
LOCATION %in% c("FRA", "DEU", "KOR")) %>%
left_join(SHA_var$LOCATION, by = "LOCATION") %>%
year_to_date %>%
left_join(colors, by = c("Location" = "country")) %>%
mutate(obsValue = obsValue/100) %>%
ggplot() + geom_line(aes(x = date, y = obsValue, color = color)) +
scale_color_identity() + theme_minimal() + add_3flags +
scale_x_date(breaks = seq(1920, 2025, 5) %>% paste0("-01-01") %>% as.Date,
labels = date_format("%y")) +
scale_y_continuous(breaks = 0.01*seq(-7, 60, 0.05),
labels = scales::percent_format(accuracy = 0.01)) +
ylab("Preventive Care (% of GDP)") + xlab("")
SHA %>%
filter(HC == "HC62",
MEASURE == "PARPIB",
HP == "HPTOT",
HF == "HFTOT") %>%
left_join(SHA_var$LOCATION, by = "LOCATION") %>%
group_by(LOCATION, Location) %>%
summarise(Nobs = n(),
`Year 1` = first(obsTime),
`Immunisation 1 (% of GDP)` = first(obsValue),
`Year 2` = last(obsTime),
`Immunisation 2 (% of GDP)` = last(obsValue)) %>%
arrange(-`Immunisation 2 (% of GDP)`) %>%
print_table_conditional()
SHA %>%
filter(HC == "HC62",
MEASURE == "PARPIB",
HP == "HPTOT",
HF == "HFTOT",
LOCATION %in% c("FRA", "DEU", "KOR")) %>%
left_join(SHA_var$LOCATION, by = "LOCATION") %>%
year_to_date %>%
left_join(colors, by = c("Location" = "country")) %>%
mutate(obsValue = obsValue/100) %>%
ggplot() + geom_line(aes(x = date, y = obsValue, color = color)) +
scale_color_identity() + theme_minimal() + add_3flags +
scale_x_date(breaks = seq(1920, 2025, 5) %>% paste0("-01-01") %>% as.Date,
labels = date_format("%y")) +
scale_y_continuous(breaks = 0.01*seq(-7, 60, 0.01),
labels = scales::percent_format(accuracy = 0.01)) +
ylab("Immunisation (% of GDP)") + xlab("")
SHA %>%
filter(HC == "HC62",
MEASURE == "PARPIB",
HP == "HPTOT",
HF == "HFTOT") %>%
left_join(SHA_var$LOCATION, by = "LOCATION") %>%
group_by(LOCATION, Location) %>%
summarise(Nobs = n(),
`Year 1` = first(obsTime),
`Early Detection 1 (% of GDP)` = first(obsValue),
`Year 2` = last(obsTime),
`Early Detection 2 (% of GDP)` = last(obsValue)) %>%
arrange(-`Early Detection 2 (% of GDP)`) %>%
print_table_conditional()
SHA %>%
filter(HC == "HC63",
MEASURE == "PARPIB",
HP == "HPTOT",
HF == "HFTOT",
LOCATION %in% c("FRA", "DEU", "KOR")) %>%
left_join(SHA_var$LOCATION, by = "LOCATION") %>%
year_to_date %>%
left_join(colors, by = c("Location" = "country")) %>%
mutate(obsValue = obsValue/100) %>%
ggplot() + geom_line(aes(x = date, y = obsValue, color = color)) +
scale_color_identity() + theme_minimal() + add_3flags +
scale_x_date(breaks = seq(1920, 2025, 5) %>% paste0("-01-01") %>% as.Date,
labels = date_format("%y")) +
scale_y_continuous(breaks = 0.01*seq(-7, 60, 0.01),
labels = scales::percent_format(accuracy = 0.01)) +
ylab("Early disease detection programmes (% of GDP)") + xlab("")
SHA %>%
filter(HC == "HC62",
MEASURE == "PARPIB",
HP == "HPTOT",
HF == "HFTOT") %>%
left_join(SHA_var$LOCATION, by = "LOCATION") %>%
group_by(LOCATION, Location) %>%
summarise(Nobs = n(),
`Year 1` = first(obsTime),
`Surveillance 1 (% of GDP)` = first(obsValue),
`Year 2` = last(obsTime),
`Surveillance 2 (% of GDP)` = last(obsValue)) %>%
arrange(-`Surveillance 2 (% of GDP)`) %>%
print_table_conditional()
SHA %>%
filter(HC == "HC65",
MEASURE == "PARPIB",
HP == "HPTOT",
HF == "HFTOT",
LOCATION %in% c("FRA", "DEU", "KOR")) %>%
left_join(SHA_var$LOCATION, by = "LOCATION") %>%
year_to_date %>%
left_join(colors, by = c("Location" = "country")) %>%
mutate(obsValue = obsValue/100) %>%
ggplot() + geom_line(aes(x = date, y = obsValue, color = color)) +
scale_color_identity() + theme_minimal() + add_3flags +
scale_x_date(breaks = seq(1920, 2025, 5) %>% paste0("-01-01") %>% as.Date,
labels = date_format("%y")) +
scale_y_continuous(breaks = 0.01*seq(-7, 60, 0.01),
labels = scales::percent_format(accuracy = 0.01),
limits = c(0, 0.0012)) +
ylab("Epidemio. surveillance,risk & disease control (% of GDP)") + xlab("")
SHA %>%
filter(HC == "HC62",
MEASURE == "PARPIB",
HP == "HPTOT",
HF == "HFTOT") %>%
left_join(SHA_var$LOCATION, by = "LOCATION") %>%
group_by(LOCATION, Location) %>%
summarise(Nobs = n(),
`Year 1` = first(obsTime),
`Disaster Preparedness 1 (% of GDP)` = first(obsValue),
`Year 2` = last(obsTime),
`Disaster Preparedness 2 (% of GDP)` = last(obsValue)) %>%
arrange(-`Disaster Preparedness 2 (% of GDP)`) %>%
print_table_conditional()
SHA %>%
filter(HC == "HC65",
MEASURE == "PARPIB",
HP == "HPTOT",
HF == "HFTOT",
LOCATION %in% c("FRA", "DEU", "KOR")) %>%
left_join(SHA_var$LOCATION, by = "LOCATION") %>%
year_to_date %>%
left_join(colors, by = c("Location" = "country")) %>%
mutate(obsValue = obsValue/100) %>%
ggplot() + geom_line(aes(x = date, y = obsValue, color = color)) +
scale_color_identity() + theme_minimal() + add_3flags +
scale_x_date(breaks = seq(1920, 2025, 5) %>% paste0("-01-01") %>% as.Date,
labels = date_format("%y")) +
scale_y_continuous(breaks = 0.01*seq(-7, 60, 0.01),
labels = scales::percent_format(accuracy = 0.01),
limits = c(0, 0.0012)) +
ylab("Disaster Preparedness (% of GDP)") + xlab("")
SHA %>%
filter(HC == "HC7",
MEASURE == "PARPIB",
HP == "HPTOT",
HF == "HFTOT") %>%
left_join(SHA_var$LOCATION %>%
setNames(c("LOCATION", "Location")), by = "LOCATION") %>%
group_by(LOCATION, Location) %>%
summarise(Nobs = n(),
`Year 1` = first(obsTime),
`Administration 1 (% of GDP)` = first(obsValue),
`Year 2` = last(obsTime),
`Administration 2 (% of GDP)` = last(obsValue)) %>%
arrange(-`Administration 2 (% of GDP)`) %>%
print_table_conditional()
SHA %>%
filter(HC == "HC7",
MEASURE == "PARPIB",
HP == "HPTOT",
HF == "HFTOT",
LOCATION %in% c("FRA", "DEU", "KOR")) %>%
left_join(SHA_var$LOCATION, by = "LOCATION") %>%
year_to_date %>%
left_join(colors, by = c("Location" = "country")) %>%
mutate(obsValue = obsValue/100) %>%
ggplot() + geom_line(aes(x = date, y = obsValue, color = color)) +
scale_color_identity() + theme_minimal() + add_3flags +
scale_x_date(breaks = seq(1920, 2025, 5) %>% paste0("-01-01") %>% as.Date,
labels = date_format("%y")) +
scale_y_continuous(breaks = 0.01*seq(-7, 60, 0.05),
labels = scales::percent_format(accuracy = 0.01)) +
ylab("Administration (% of GDP)") + xlab("")
SHA %>%
filter(HC == "HC72",
MEASURE == "PARPIB",
HP == "HPTOT",
HF == "HFTOT") %>%
left_join(SHA_var$LOCATION, by = "LOCATION") %>%
group_by(LOCATION, Location) %>%
summarise(Nobs = n(),
`Year 1` = first(obsTime),
`Administration 1 (% of GDP)` = first(obsValue),
`Year 2` = last(obsTime),
`Administration 2 (% of GDP)` = last(obsValue)) %>%
arrange(-`Administration 2 (% of GDP)`) %>%
print_table_conditional()
SHA %>%
filter(HC == "HC72",
MEASURE == "PARPIB",
HP == "HPTOT",
HF == "HFTOT",
LOCATION %in% c("FRA", "DEU", "KOR")) %>%
left_join(SHA_var$LOCATION, by = "LOCATION") %>%
year_to_date %>%
left_join(colors, by = c("Location" = "country")) %>%
mutate(obsValue = obsValue/100) %>%
ggplot() + geom_line(aes(x = date, y = obsValue, color = color)) +
scale_color_identity() + theme_minimal() + add_3flags +
scale_x_date(breaks = seq(1920, 2025, 5) %>% paste0("-01-01") %>% as.Date,
labels = date_format("%y")) +
scale_y_continuous(breaks = 0.01*seq(-7, 60, 0.05),
labels = scales::percent_format(accuracy = 0.01)) +
ylab("Administration (% of GDP)") + xlab("")