Learn R Programming

MexicoDataAPI (version 0.1.0)

get_mexico_unemployment: Get Mexico's Unemployment Rate from World Bank

Description

Retrieves Mexico's total unemployment rate as a percentage of the total labor force from 2010 to 2022 using the World Bank Open Data API.

Usage

get_mexico_unemployment()

Arguments

Value

A tibble with four columns: `indicator` (name of the indicator), `country` (country name), `year` (year of observation), and `value` (unemployment rate as a numeric percentage).

Details

The function sends a GET request to the World Bank API. If the request fails or returns a status other than 200, the function returns NULL with an informative message.

See Also

Examples

Run this code
if (FALSE) {
get_mexico_unemployment()
}

Run the code above in your browser using DataLab