Fetch countries data with official language ending in specified character
Source:R/subsetted.R
languageEndsWith.Rd
Obtain country data matching language first one or more letters
Arguments
- char
character to search in languages
- full.list
whether to return only name of country or full list
See also
countryStartsWith
for country search starting with specified characters, and [countryEndsWith()] for countries that end with a specified characters.
Examples
# task 1: get only language names that ends with "EN" or "en"
# note that the search in case-insensitive
languageEndsWith("eN", full.list = FALSE)
#> [1] "Turkmen"
# task 2: get only language names that ends with "chi"
languageEndsWith("chi", full.list = FALSE)
#> NULL
# task 3: repeat task 2, but return full list for each country with the language
languageEndsWith("sin", full.list = TRUE)
#> NULL
# searching text with no results
languageEndsWith("er", full.list = FALSE)
#> [1] "Arabic, Berber" "Khmer"