
Get Indonesia's Unemployment Rate from World Bank
Source:R/get_indonesia_unemployment.R
get_indonesia_unemployment.RdRetrieves Indonesia's Unemployment, total (
for the years 2010 to 2022 using the World Bank Open Data API.
The indicator used is SL.UEM.TOTL.ZS.
Source
World Bank Open Data API: https://data.worldbank.org/indicator/SL.UEM.TOTL.ZS
Value
A tibble with:
indicator: Indicator name.country: Country name ("Indonesia").year: Year (integer).value: Unemployment rate (numeric).value_label: Formatted unemployment rate (e.g., "5.2
Returns NULL if API request fails or data is unavailable.
Details
If the API request fails for any reason (network issue, timeout,
invalid HTTP status, or malformed JSON), the function returns NULL
with an informative message.
Examples
# \donttest{
get_indonesia_unemployment()
#> # A tibble: 13 × 5
#> indicator country year value value_label
#> <chr> <chr> <int> <dbl> <chr>
#> 1 Unemployment, total (% of total labor force)… Indone… 2022 3.46 3.5%
#> 2 Unemployment, total (% of total labor force)… Indone… 2021 3.83 3.8%
#> 3 Unemployment, total (% of total labor force)… Indone… 2020 4.26 4.3%
#> 4 Unemployment, total (% of total labor force)… Indone… 2019 3.59 3.6%
#> 5 Unemployment, total (% of total labor force)… Indone… 2018 4.39 4.4%
#> 6 Unemployment, total (% of total labor force)… Indone… 2017 3.78 3.8%
#> 7 Unemployment, total (% of total labor force)… Indone… 2016 4.30 4.3%
#> 8 Unemployment, total (% of total labor force)… Indone… 2015 4.51 4.5%
#> 9 Unemployment, total (% of total labor force)… Indone… 2014 4.05 4.0%
#> 10 Unemployment, total (% of total labor force)… Indone… 2013 4.34 4.3%
#> 11 Unemployment, total (% of total labor force)… Indone… 2012 4.47 4.5%
#> 12 Unemployment, total (% of total labor force)… Indone… 2011 5.15 5.2%
#> 13 Unemployment, total (% of total labor force)… Indone… 2010 5.61 5.6%
# }