source | dataset | .html | .RData |
---|---|---|---|
eurostat | api | 2024-06-04 | NA |
source | dataset | .html | .RData |
---|---|---|---|
bdf | api | 2024-05-24 | NA |
bea | api | 2024-02-11 | NA |
bis | api | 2024-04-19 | NA |
bls | api | 2024-02-11 | NA |
ecb | api | 2024-06-07 | NA |
eurostat | api | 2024-06-04 | NA |
imf | api | 2024-02-11 | NA |
insee | api | 2024-06-07 | NA |
oecd | api | 2024-05-07 | 2024-04-16 |
rdb | api | NA | NA |
wdi | api | 2024-04-14 | NA |
All datasets: https://ec.europa.eu/eurostat/api/dissemination/sdmx/2.1/dataflow/ESTAT/all
All codelists: https://ec.europa.eu/eurostat/api/dissemination/sdmx/2.1/codelist/ESTAT/all
API for data access: https://wikis.ec.europa.eu/display/EUROSTATHELP/API+for+data+access
JSON example: https://ec.europa.eu/eurostat/api/dissemination/statistics/1.0/data/nama_10_gdp?format=JSON&lang=EN&time=2019
Examples:
"https://ec.europa.eu/eurostat/api/dissemination/sdmx/2.1/datastructure/ESTAT/namq_10_gdp" %>%
readSDMX() %>%
slot("datastructures") %>%
pluck(1) %>%
slot("Components") %>%
as_tibble %>%
print_table_conditional()
component | conceptRef | conceptVersion | conceptAgency | conceptSchemeRef | conceptSchemeAgency | codelist | codelistVersion | codelistAgency | isMeasureDimension | isFrequencyDimension | isEntityDimension | isCountDimension | isNonObservationTimeDimension | isIdentityDimension | crossSectionalAttachDataset | crossSectionalAttachGroup | crossSectionalAttachSection | crossSectionalAttachObservation |
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
Dimension | freq | 63.2 | ESTAT | NA | NA | FREQ | 3.3 | ESTAT | FALSE | FALSE | FALSE | FALSE | FALSE | FALSE | NA | NA | NA | NA |
Dimension | unit | 63.2 | ESTAT | NA | NA | UNIT | 31.1 | ESTAT | FALSE | FALSE | FALSE | FALSE | FALSE | FALSE | NA | NA | NA | NA |
Dimension | s_adj | 63.2 | ESTAT | NA | NA | S_ADJ | 1.10 | ESTAT | FALSE | FALSE | FALSE | FALSE | FALSE | FALSE | NA | NA | NA | NA |
Dimension | na_item | 63.2 | ESTAT | NA | NA | NA_ITEM | 17.0 | ESTAT | FALSE | FALSE | FALSE | FALSE | FALSE | FALSE | NA | NA | NA | NA |
Dimension | geo | 63.2 | ESTAT | NA | NA | GEO | 20.1 | ESTAT | FALSE | FALSE | FALSE | FALSE | FALSE | FALSE | NA | NA | NA | NA |
TimeDimension | TIME_PERIOD | 63.2 | ESTAT | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA |
PrimaryMeasure | OBS_VALUE | 63.2 | ESTAT | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA |
Attribute | OBS_FLAG | 63.2 | ESTAT | NA | NA | OBS_FLAG | 1.34 | ESTAT | FALSE | FALSE | FALSE | FALSE | FALSE | FALSE | NA | NA | NA | NA |
"https://ec.europa.eu/eurostat/api/dissemination/sdmx/2.1/datastructure/ESTAT/prc_hicp_manr" %>%
readSDMX() %>%
slot("datastructures") %>%
pluck(1) %>%
slot("Components") %>%
as_tibble %>%
print_table_conditional()
component | conceptRef | conceptVersion | conceptAgency | conceptSchemeRef | conceptSchemeAgency | codelist | codelistVersion | codelistAgency | isMeasureDimension | isFrequencyDimension | isEntityDimension | isCountDimension | isNonObservationTimeDimension | isIdentityDimension | crossSectionalAttachDataset | crossSectionalAttachGroup | crossSectionalAttachSection | crossSectionalAttachObservation |
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
Dimension | freq | 44.1 | ESTAT | NA | NA | FREQ | 3.2 | ESTAT | FALSE | FALSE | FALSE | FALSE | FALSE | FALSE | NA | NA | NA | NA |
Dimension | unit | 44.1 | ESTAT | NA | NA | UNIT | 31.0 | ESTAT | FALSE | FALSE | FALSE | FALSE | FALSE | FALSE | NA | NA | NA | NA |
Dimension | coicop | 44.1 | ESTAT | NA | NA | COICOP | 6.1 | ESTAT | FALSE | FALSE | FALSE | FALSE | FALSE | FALSE | NA | NA | NA | NA |
Dimension | geo | 44.1 | ESTAT | NA | NA | GEO | 20.1 | ESTAT | FALSE | FALSE | FALSE | FALSE | FALSE | FALSE | NA | NA | NA | NA |
TimeDimension | TIME_PERIOD | 44.1 | ESTAT | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA |
PrimaryMeasure | OBS_VALUE | 44.1 | ESTAT | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA |
Attribute | OBS_FLAG | 44.1 | ESTAT | NA | NA | OBS_FLAG | 1.33 | ESTAT | FALSE | FALSE | FALSE | FALSE | FALSE | FALSE | NA | NA | NA | NA |
"https://ec.europa.eu/eurostat/api/dissemination/sdmx/2.1/datastructure/ESTAT/hbs_str_t223" %>%
readSDMX() %>%
slot("datastructures") %>%
pluck(1) %>%
slot("Components") %>%
as_tibble %>%
print_table_conditional()
component | conceptRef | conceptVersion | conceptAgency | conceptSchemeRef | conceptSchemeAgency | codelist | codelistVersion | codelistAgency | isMeasureDimension | isFrequencyDimension | isEntityDimension | isCountDimension | isNonObservationTimeDimension | isIdentityDimension | crossSectionalAttachDataset | crossSectionalAttachGroup | crossSectionalAttachSection | crossSectionalAttachObservation |
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
Dimension | freq | 34.1 | ESTAT | NA | NA | FREQ | 3.2 | ESTAT | FALSE | FALSE | FALSE | FALSE | FALSE | FALSE | NA | NA | NA | NA |
Dimension | quantile | 34.1 | ESTAT | NA | NA | QUANTILE | 1.4 | ESTAT | FALSE | FALSE | FALSE | FALSE | FALSE | FALSE | NA | NA | NA | NA |
Dimension | coicop | 34.1 | ESTAT | NA | NA | COICOP | 6.1 | ESTAT | FALSE | FALSE | FALSE | FALSE | FALSE | FALSE | NA | NA | NA | NA |
Dimension | unit | 34.1 | ESTAT | NA | NA | UNIT | 31.0 | ESTAT | FALSE | FALSE | FALSE | FALSE | FALSE | FALSE | NA | NA | NA | NA |
Dimension | geo | 34.1 | ESTAT | NA | NA | GEO | 20.1 | ESTAT | FALSE | FALSE | FALSE | FALSE | FALSE | FALSE | NA | NA | NA | NA |
TimeDimension | TIME_PERIOD | 34.1 | ESTAT | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA |
PrimaryMeasure | OBS_VALUE | 34.1 | ESTAT | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA | NA |
Attribute | OBS_FLAG | 34.1 | ESTAT | NA | NA | OBS_FLAG | 1.33 | ESTAT | FALSE | FALSE | FALSE | FALSE | FALSE | FALSE | NA | NA | NA | NA |
"https://ec.europa.eu/eurostat/api/dissemination/sdmx/2.1/codelist/ESTAT/FREQ" %>%
readSDMX() %>%
as_tibble %>%
select(1, 4) %>%
print_table_conditional()
id | label.en |
---|---|
P | Pluri-annual |
A | Annual |
S | Half-yearly, semesterly |
Q | Quarterly |
M | Monthly |
W | Weekly |
B | Daily - business week |
D | Daily |
H | Hourly |
I | Irregular / A-periodic |
NAP | Not applicable |
data_structure <- "https://ec.europa.eu/eurostat/api/dissemination/sdmx/2.1/datastructure/ESTAT/NAMA_10_GDP/28.0" %>%
readSDMX()
components <- "https://ec.europa.eu/eurostat/api/dissemination/sdmx/2.1/datastructure/ESTAT/NAMQ_10_GDP" %>%
readSDMX() %>%
slot("datastructures") %>%
pluck(1) %>%
slot("Components") %>%
as_tibble
components <- "https://ec.europa.eu/eurostat/api/dissemination/sdmx/2.1/datastructure/ESTAT/NAMQ_10_GDP" %>%
readSDMX() %>%
slot("datastructures") %>%
pluck(1) %>%
slot("Components") %>%
as_tibble
Concept_scheme <- "https://ec.europa.eu/eurostat/api/dissemination/sdmx/2.1/conceptscheme/ESTAT/ISOC_CI_ID_H/28.0" %>%
readSDMX()
https://ec.europa.eu/eurostat/api/dissemination/sdmx/2.1/codelist/ESTAT/FREQ/1.31
"https://ec.europa.eu/eurostat/api/dissemination/sdmx/2.1/data/UNE_RT_M/M.SA.TOTAL.PC_ACT.T.EA20+FR" %>%
rsdmx::readSDMX() %>%
as_tibble %>%
mutate(date = obsTime %>% paste0("-01-01") %>% as.Date()) %>%
filter(date >= as.Date("2000-01-01")) %>%
ggplot + geom_line(aes(x = date, y = obsValue/100, color = geo)) +
theme_minimal() + xlab("") + ylab("") +
scale_x_date(breaks = as.Date(paste0(seq(1960, 2100, 1), "-01-01")),
labels = date_format("%Y")) +
theme(axis.text.x = element_text(angle = 45, vjust = 1, hjust = 1),
legend.position = c(0.2, 0.8),
legend.title = element_blank()) +
scale_color_manual(values = c("#003399", "#ED2939")) +
xlab("") + ylab("Unemployment, Percentage of active population") +
scale_y_continuous(breaks = 0.01*seq(0, 200, 1),
labels = scales::percent_format(accuracy = 1))
geo <- "https://ec.europa.eu/eurostat/api/dissemination/sdmx/2.1/codelist/ESTAT/GEO" %>%
readSDMX() %>%
as_tibble %>%
select(1, 4) %>%
setNames(c("geo", "Geo"))
"https://ec.europa.eu/eurostat/api/dissemination/sdmx/2.1/data/UNE_RT_M/M.SA.TOTAL.PC_ACT.T.EA20+FR" %>%
rsdmx::readSDMX() %>%
as_tibble %>%
mutate(date = obsTime %>% paste0("-01-01") %>% as.Date()) %>%
filter(date >= as.Date("2000-01-01")) %>%
left_join(geo, by = "geo") %>%
ggplot + geom_line(aes(x = date, y = obsValue/100, color = Geo)) +
theme_minimal() + xlab("") + ylab("") +
scale_x_date(breaks = as.Date(paste0(seq(1960, 2100, 1), "-01-01")),
labels = date_format("%Y")) +
theme(axis.text.x = element_text(angle = 45, vjust = 1, hjust = 1),
legend.position = c(0.2, 0.8),
legend.title = element_blank()) +
scale_color_manual(values = c("#003399", "#ED2939")) +
xlab("") + ylab("Unemployment, Percentage of active population") +
scale_y_continuous(breaks = 0.01*seq(0, 200, 1),
labels = scales::percent_format(accuracy = 1))
Getting started with SDMX 2.1
Bulk Download Facility: https://ec.europa.eu/eurostat/estat-navtree-portlet-prod/BulkDownloadListing
Listing: https://ec.europa.eu/eurostat/estat-navtree-portlet-prod/BulkDownloadListing?sort=1&dir=data
get_eurostat_raw
: https://rdrr.io/cran/eurostat/src/R/get_eurostat_raw.R.