View source: R/get_colombia_airports.R
| get_colombia_airports | R Documentation |
Retrieves comprehensive information about all Colombian airports from the API Colombia service. This function fetches data including airport names, codes, types, locations, and geographical coordinates for all airports across Colombia's departments.
get_colombia_airports()
This function sends a GET request to the API Colombia service.
If the API request fails or returns an error status code,
the function returns NULL with an informative message.
Note: The API returns latitude and longitude values swapped, so this function
corrects the coordinates by swapping them back to their correct positions.
A tibble with the following columns:
id: Airport identifier (integer)
name: Airport name (character)
iata_code: IATA airport code (character)
oaci_code: ICAO airport code (character)
type: Airport type (character)
city: City where airport is located (character)
department: Department where airport is located (character)
latitude: Latitude coordinates (numeric)
longitude: Longitude coordinates (numeric)
Requires internet connection.
API Colombia: https://api-colombia.com/api/v1/Airport
GET, fromJSON, as_tibble
if (interactive()) {
get_colombia_airports()
}
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.