[R] Help with setting locale

Ivan Krylov kry|ov@r00t @end|ng |rom gm@||@com
Mon Sep 17 10:42:08 CEST 2018


On Sun, 16 Sep 2018 21:18:45 +0200
Kim Titcombe <ktitcombe02 using gmail.com> wrote:

> I have Windows 10. English version.

Do you have any other problems, besides the warning message at startup?

According to MSDN[1], the combination of English language
and Swiss cultural rules should be supported in Windows 10 >=
v1607 with a call like Sys.setlocale(locale="English_Switzerland"). If
that doesn't work, Sys.setlocale(locale="English") seemed to work even
on my Windows 2008 machine[2]. However, for some reason, when I call
setlocale() with two-letter arguments exactly as described on that page
("en-US", "en-CH", etc) the call fails.

-- 
Best regards,
Ivan

[1]: https://msdn.microsoft.com/library/cc233982.aspx

[2]: Also worked:

> Sys.setlocale(locale="English_United States")
[1] "LC_COLLATE=English_United States.1252;LC_CTYPE=English_United States.1252;LC_MONETARY=English_United States.1252;LC_NUMERIC=C;LC_TIME=English_United States.1252"
> Sys.setlocale(locale="English_United Kingdom")
[1] "LC_COLLATE=English_United Kingdom.1252;LC_CTYPE=English_United Kingdom.1252;LC_MONETARY=English_United Kingdom.1252;LC_NUMERIC=C;LC_TIME=English_United Kingdom.1252"




More information about the R-help mailing list