info_locales: View a table with info on supported locales

View source: R/info_tables.R

info_localesR Documentation

View a table with info on supported locales


Many of the ⁠fmt_*()⁠ functions have a locale argument that makes locale-based formatting easier. The table generated by the info_locales() function provides a quick reference to all the available locales. The locale identifiers are provided (base locale ID, common display name) along with the each locale's group and decimal separator marks. A formatted numeric example is provided (based on the value of 11027) to demonstrate the default formatting of each locale.


info_locales(begins_with = NULL)



Show locales beginning with a specific letter

⁠scalar<character>⁠ // default: NULL (optional)

Providing a single letter will filter locales to only those that begin with that letter in their locale ID. The default (NULL) will produce a table with all locales displayed


There are 712 locales, which means that a very long display table is provided by default. To trim down the output table size, we can provide an initial letter corresponding to the base locale ID to begins_with. This will filter locales in the info table to just the set that begins with the supplied letter.


An object of class gt_tbl.


Get a table of info on all of the locales where the base locale ID begins with a "v".

info_locales(begins_with = "v")
This image of a table was generated from the first code example in the `info_locales()` help file.

Function ID


Function Introduced

v0.2.0.5 (March 31, 2020)

See Also

Other information functions: info_currencies(), info_date_style(), info_flags(), info_google_fonts(), info_icons(), info_paletteer(), info_time_style()

gt documentation built on June 22, 2024, 11:11 a.m.