source | dataset | .html | .qmd | .RData |
---|---|---|---|---|
eurostat | tipsii10 | 2024-11-05 | 2024-06-14 | 2024-10-08 |
Net international investment position - annual data
Data - Eurostat
Info
DOWNLOAD_TIME
Code
tibble(DOWNLOAD_TIME = as.Date(file.info("~/Library/Mobile\ Documents/com~apple~CloudDocs/website/data/eurostat/tipsii10.RData")$mtime)) %>%
print_table_conditional()
DOWNLOAD_TIME |
---|
2024-10-08 |
Last
Code
%>%
tipsii10 group_by(time) %>%
summarise(Nobs = n()) %>%
arrange(desc(time)) %>%
head(1) %>%
print_table_conditional()
time | Nobs |
---|---|
2023 | 57 |
geo
Code
%>%
tipsii10 left_join(geo, by = "geo") %>%
group_by(geo, Geo) %>%
summarise(Nobs = n()) %>%
arrange(-Nobs) %>%
mutate(Geo = ifelse(geo == "DE", "Germany", Geo)) %>%
mutate(Flag = gsub(" ", "-", str_to_lower(Geo)),
Flag = paste0('<img src="../../bib/flags/vsmall/', Flag, '.png" alt="Flag">')) %>%
select(Flag, everything()) %>%
if (is_html_output()) datatable(., filter = 'top', rownames = F, escape = F) else .} {
unit
Code
%>%
tipsii10 left_join(unit, by = "unit") %>%
group_by(unit, Unit) %>%
summarise(Nobs = n()) %>%
arrange(-Nobs) %>%
print_table_conditional()
unit | Unit | Nobs |
---|---|---|
PC_GDP | Percentage of gross domestic product (GDP) | 675 |
MIO_NAC | Million units of national currency | 661 |
time
Code
%>%
tipsii10 group_by(time) %>%
summarise(Nobs = n()) %>%
arrange(desc(time)) %>%
print_table_conditional()
time | Nobs |
---|---|
2023 | 57 |
2022 | 57 |
2021 | 57 |
2020 | 57 |
2019 | 57 |
2018 | 57 |
2017 | 57 |
2016 | 57 |
2015 | 57 |
2014 | 57 |
2013 | 57 |
2012 | 54 |
2011 | 54 |
2010 | 54 |
2009 | 54 |
2008 | 54 |
2007 | 54 |
2006 | 54 |
2005 | 54 |
2004 | 48 |
2003 | 40 |
2002 | 36 |
2001 | 32 |
2000 | 32 |
1999 | 30 |
1998 | 18 |
1997 | 15 |
1996 | 15 |
1995 | 11 |
Table
Code
%>%
tipsii10 filter(unit == "PC_GDP",
== "2020") %>%
time select_if(~ n_distinct(.) > 1) %>%
left_join(geo, by = "geo") %>%
select(geo, Geo, values) %>%
arrange(-values) %>%
mutate(Geo = ifelse(geo == "DE", "Germany", Geo)) %>%
mutate(Flag = gsub(" ", "-", str_to_lower(Geo)),
Flag = paste0('<img src="../../bib/flags/vsmall/', Flag, '.png" alt="Flag">')) %>%
select(Flag, everything()) %>%
if (is_html_output()) datatable(., filter = 'top', rownames = F, escape = F) else .} {
France, Germany, Italy, Belgium, Netherlands
Code
%>%
tipsii10 filter(geo %in% c("DE", "BE", "FR", "IT", "NL", "ES"),
== "PC_GDP") %>%
unit %>%
year_to_date left_join(geo, by = "geo") %>%
left_join(colors, by = c("Geo" = "country")) %>%
mutate(values = values/100) %>%
+ geom_line(aes(x = date, y = values, color = color)) + theme_minimal() +
ggplot scale_color_identity() + add_6flags +
scale_x_date(breaks = as.Date(paste0(seq(1960, 2030, 2), "-01-01")),
labels = date_format("%Y")) +
xlab("") + ylab("Net international investment position - annual data") +
scale_y_continuous(breaks = 0.01*seq(-300, 200, 10),
labels = scales::percent_format(accuracy = 1)) +
geom_hline(yintercept = -0.35, linetype = "dashed") +
geom_hline(yintercept = 0, linetype = "solid")
France, Germany, Italy, Spain, Netherlands
Code
%>%
tipsii10 filter(geo %in% c("DE", "ES", "FR", "IT", "NL"),
== "PC_GDP") %>%
unit %>%
year_to_date left_join(geo, by = "geo") %>%
left_join(colors, by = c("Geo" = "country")) %>%
mutate(values = values/100) %>%
+ geom_line(aes(x = date, y = values, color = color)) + theme_minimal() +
ggplot scale_color_identity() + add_5flags +
scale_x_date(breaks = as.Date(paste0(seq(1960, 2030, 2), "-01-01")),
labels = date_format("%Y")) +
xlab("") + ylab("Net international investment position - annual data") +
scale_y_continuous(breaks = 0.01*seq(-300, 200, 20),
labels = scales::percent_format(accuracy = 1)) +
geom_hline(yintercept = -0.35, linetype = "dashed") +
geom_hline(yintercept = 0, linetype = "solid")