| latinize | R Documentation |
Helper tool to transliterate various encodings to latin. Attempts to
convert a character vector from its current encoding to "latin1" and -
if it fails - defaults back to the original term. This can be useful
for geocode and structured when attempting to
geocode terms containing symbols that photon does not support.
latinize(x, encoding = "latin1")
x |
A character vector. |
encoding |
Encoding that the strings in |
The transliterated vector of the same length as x. NAs
are avoided.
# converts fancy apostrophes to normal ones
latinize("Luatuanu\u2019u")
# does nothing
latinize("Berlin")
# also does nothing, although it would fail with `iconv`
latinize("\u0391\u03b8\u03ae\u03bd\u03b1")
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.