[R] Comparing Latin characters with and without accents?

Spencer Graves spencer.graves at structuremonitoring.com
Sun Nov 30 11:14:09 CET 2014


       How can one convert Latin characters with to the corresponding 
characters without?  For example, I want to convert "ú" to "u", similar 
to how tolower('U') returns "u".

       This can be done using chartr{base}, e.g., chartr('ú', 'u', 
'Raúl') returns "Raul".  However, I wondered if a simpler version of 
this is available.


p.s.   findFn('convert to ascii') found 117 help pages in 70 packages.  
A brief review identified two to "Convert to ASCII": ASCIIfy {gtools} 
and stri_enc_toascii {stringi}.  Neither of these did what I expected.

More information about the R-help mailing list