R-beta: R and LANG
gb at stat.umu.se
Thu Jan 8 16:32:47 CET 1998
On 8 Jan 1998, Peter Dalgaard BSA wrote:
> Goran Brostrom <gb at stat.umu.se> writes:
> > I am running R 0.61.0 on a Sparc 5, Solaris 2.4, in tcsh. Today I
> > couldn't, to my big surprise, scan a data file in R. As I finally
> > understood it, R wanted a decimal comma instead of a decimal point,
> > because LANG was set to 'sv'. See my runs below. I wonder why this
> Apparently, the strtod() C library function accepts different formats
> depending on locale settings, so probably the setlocale(LC_ALL,""); in
> src/main/main.c is doing you in.
> This is the same thing that allows you to have a variable called
> "föräldre" and see come out right on plots, etc., so you don't want to
> remove that line.
> I think that either you should setenv LC_NUMERIC to C or POSIX or R
> should only set LC_CTYPE (and maybe some of the others?).
Yes, the combination (LANG = sv & LC_NUMERIC = C) seems to work properly.
r-help mailing list -- Read http://www.ci.tuwien.ac.at/~hornik/R/R-FAQ.html
Send "info", "help", or "[un]subscribe"
(in the "body", not the subject !) To: r-help-request at stat.math.ethz.ch
More information about the R-help