search for: setlocale

Displaying 20 results from an estimated 403 matches for "setlocale".

2010 Nov 24
4
R encoding question
Hi, I am using RpgSQL to retrieve data from a PostgreSQL database wich is with encoding UTF8, and I have some Chinese character in one of the columns, unfortunately R can't show it correctly. > df <- dbGetQuery(con, "select * from test") > df a b 1 1 ????????\xa2 2 2 ???? EURO\xa1 I see the following option, do I need to change the encoding option to show
2010 Dec 10
1
Consistency of variable storage in R and Sys.setlocale (is this a feature or bug)?
<I was not sure if this should go to R-devel or R-help. If I e-mailed this to the wrong place, please let me know.> Hello dear R-devel members, I came by an oddity, with regards to how character variables are being transformed when they are in Hebrew, and when Sys.setlocale is changed. Here is an example: # first, let's set the locale to Hebrew Sys.setlocale("LC_ALL", "Hebrew") # Setting locale x <- "שלום" # Now let's put "Peace" (in Hebrew) into variable x > x #[1] "שלום" # it is still correctly pre...
2017 Jun 23
2
LC_TIME not set correctly by Sys.setlocale() ?
Related to the following question on Stackoverflow: https://stackoverflow.com/questions/44723690/unexpected-behavior-of-sys-setlocale#44723690 It appears as if Sys.setlocale() does not update LC_TIME correctly for use in date formatting. Although R reports that LC_TIME is changed to the new setting after use of Sys.setlocale(), as.Date() still uses the old settings. The only way to update this is by specifically using LC_TIME....
2014 Jan 30
2
[PATCH] builder: output translated notes
...uot;C". The version is not bumped though, since there have been no stable releases with the former output yet. --- builder/Makefile.am | 5 ++++ builder/index_parser.ml | 11 ++++---- builder/list_entries.ml | 55 +++++++++++++++++++++++++++++++----- builder/setlocale-c.c | 59 +++++++++++++++++++++++++++++++++++++++ builder/setlocale.ml | 29 +++++++++++++++++++ builder/setlocale.mli | 30 ++++++++++++++++++++ builder/test-virt-builder-list.sh | 28 ++++++++++++++----- po/POTFILES | 1 + po/POTFILES-ml...
2017 Jun 23
0
LC_TIME not set correctly by Sys.setlocale() ?
On 23/06/2017 15:35, Joris Meys wrote: > Related to the following question on Stackoverflow: > https://stackoverflow.com/questions/44723690/unexpected-behavior-of-sys-setlocale#44723690 > > It appears as if Sys.setlocale() does not update LC_TIME correctly for use > in date formatting. Although R reports that LC_TIME is changed to the new > setting after use of Sys.setlocale(), as.Date() still uses the old > settings. The only way to update this is by spec...
2018 Mar 20
1
WISH: Sys.setlocale() to return value invisibly
Contrary to, say, Sys.setenv(), Sys.setlocale() returns it's value visibly. This means that if you for instance add: Sys.setlocale("LC_COLLATE", "C") to your .Rprofile file, it will print: [1] "C" at startup. The workaround is to wrap the call in invisible(), but I'd argue that any "setter"...
2013 Jan 27
2
[LLVMdev] problem with setLocale
In order to print unicode characters with llvm, I used setLocale in llvm ir: call i8* @setlocale(i32 6, i8* getelementptr inbounds ([1 x i8]* @pe, i32 0, i32 0)) nounwind where @pe is defined as follows: @pe = private unnamed_addr constant [1 x i8] zeroinitializer, align 1 However, I got the following error: *** glibc detected *** ./test/bin/exe...
2003 Dec 05
1
How to use Sys.setlocale("LC_NUMERIC")?
Can you help me to use Sys.setlocale("LC_NUMERIC", "cs_CZ") (comma as a decimal point) in some useful way, without all the workarounds? After switching to Sys.setlocale("LC_NUMERIC", "cs_CZ"): -- How do I set attributes in read.csv2() not to get columns of real numbers (decimal point = comma,...
2013 Jan 28
2
[LLVMdev] problem with setLocale
...an object file using llc. Then, I use clang++ to link them and generate an executable file without linking with any external libraries, so I cannot understand what you mean. Sorry, if my question sounds silly to you -- View this message in context: http://llvm.1065342.n5.nabble.com/problem-with-setLocale-tp54212p54235.html Sent from the LLVM - Dev mailing list archive at Nabble.com.
2013 Jan 27
0
[LLVMdev] problem with setLocale
Hi Ali, did you link your program statically? Try linking it dynamically. Ciao, Duncan. On 27/01/13 07:36, Ali Sedaghat wrote: > In order to print unicode characters with llvm, I used setLocale in llvm ir: > > call i8* @setlocale(i32 6, i8* getelementptr inbounds ([1 x i8]* @pe, i32 > 0, i32 0)) nounwind > > where @pe is defined as follows: > > @pe = private unnamed_addr constant [1 x i8] zeroinitializer, align 1 > > However, I got the following error:...
2013 Jan 28
0
[LLVMdev] problem with setLocale
...iles is converted to an object file using llc. > Then, I use clang++ to link them and generate an executable file without > linking with any external libraries, so I cannot understand what you mean. > Sorry, if my question sounds silly to you do you mean that you wrote your own version of setlocale? The usual setlocale lives in a system library, and to use it you must have linked with that system library. Usually a compiler like clang will automatically add that library to the list of libraries to link with, so you may not realize you linked with it. What is the exact command you used to cr...
2014 Jul 19
1
[PATCH] don't always call setlocale() on Windows
Windows (MSVC, MinGW) version of setlocale don't care about LC_* environment variables. For example, flac cannot pass the test for --until and --skip options the script calls it with --skip=0:01.1001 and it expects decimal comma (--skip=0:01,1001) on my system. One solution is to write a local version of strtod that always accepts both...
2007 Mar 11
1
Sys.setlocale("LC_CTYPE","fr_FR.UTF-8")
...script run under R-2.4.1. The script run OK under Linux but all accentuated characters appear as "?" when the script is run under Windows. As Gtk+ requires UTF-8, I thought it was the source of the problem and tried to change the default encoding (1252) in the following way: >Sys.setlocale("LC_CTYPE","fr_FR.UTF-8") [1] "fr_FR.UTF-8" But when I try as a check: >Sys.getlocale("LC_TYPE") [1] "French_France.1252" So it seems that Sys.setlocale() has not changed anything. What am I doing wrong ? Thank you for your help, Yvonnick...
2009 Jul 28
1
Sys.setlocale
When checking an R package of mine, I get * checking R files for syntax errors ... WARNING Warning in Sys.setlocale("LC_CTYPE", "en_US") : OS reports request to set locale to "en_US" cannot be honored 'Sys.setlocale' is not used in any of my R functions. What should I do to fix the Warning? I have never seen this before. My locale is "sv_SE", on ubuntu 9.04...
2017 May 19
2
test fails when requesting LC_CTYPE
...;English_United States.28605" + else if(grepl("[.]UTF-8$", oloc, ignore.case=TRUE)) # typically nowadays + oloc + else + "C.UTF-8" # or rather "en_US.UTF-8" (? from system("locale -a| fgrep .UTF-8") ) + } > stopifnot(identical(Sys.setlocale("LC_CTYPE", mbyte.lc), mbyte.lc)) Error: identical(Sys.setlocale("LC_CTYPE", mbyte.lc), mbyte.lc) is not TRUE In addition: Warning message: In Sys.setlocale("LC_CTYPE", mbyte.lc) : OS reports request to set locale to "C.UTF-8" cannot be honored Execution ha...
2006 May 22
4
Sys.setlocale upsets windows graphics device (PR#8887)
Full_Name: Edward McNeil Version: 2.3.0 OS: Widows XP Submission from: (NULL) (203.170.234.5) Type the following: > Sys.setlocale("LC_ALL","C") > hist(1:10) CRASH
2010 Apr 15
1
Changing locale?
Hi I need for a specific application to change the locale of R 2.9.2 in Ubuntu 9.04. Trying the example in ?Sys.setlocale: Sys.setlocale("LC_TIME", "de_DE.utf8") [1] "" Warning message: In Sys.setlocale("LC_TIME", "de_DE.utf8") : la requ?te OS pour sp?cifier la localisation ? "de_DE.utf8" n'a pas pu ?tre honor?e I tried the code line for windows on R...
2015 Jun 08
3
Bug in loadNamespace?
...The sessioninfo() from the former is below. > | > | Here's what I see: If I set the locale, and trigger a namespace load, a > | version comparison gives NA, and I get an error. For example, in a new > | session started with R --vanilla from the terminal: > | > | > Sys.setlocale(locale='en_US.UTF-8');grid::gpar() > | [1] "en_US.UTF-8/en_US.UTF-8/en_US.UTF-8/C/en_US.UTF-8/en_CA.UTF-8" > | Error in if (R_version_built_under < "3.0.0") stop(gettextf("package %s > | was built before R 3.0.0: please re-install it", : > | m...
2018 Aug 20
2
Call for testing: OpenSSH 7.8
...is somewhere else, likely in what your nl_langinfo(3) function does in the POSIX locale. Could you please run the following simple test program on your system and show us the output, for further diagnosis? OpenBSD: $ make nl_langinfo cc -O2 -pipe -o nl_langinfo nl_langinfo.c $ ./nl_langinfo setlocale -> "C" nl_langinfo -> "US-ASCII" Linux: $ make nl_langinfo cc nl_langinfo.c -o nl_langinfo $ ./nl_langinfo setlocale -> "C" nl_langinfo -> "ANSI_X3.4-1968" AIX: ? Thank you, Ingo $ cat nl_langinfo.c #include <err.h> #include...
2017 May 20
1
test fails when requesting LC_CTYPE
...+ else if(grepl("[.]UTF-8$", oloc, ignore.case=TRUE)) # typically nowadays > + oloc > + else > + "C.UTF-8" # or rather "en_US.UTF-8" (? from system("locale -a| fgrep .UTF-8") ) > + } >> stopifnot(identical(Sys.setlocale("LC_CTYPE", mbyte.lc), mbyte.lc)) >> oloc > [1] "en_US.UTF-8" >> mbyte.lc > [1] "en_US.UTF-8" I had been making these changes in R-devel after offline discussions with Linux users for which the original check (using "en_UK.UTF-8") f...