Re: [R] A question about JGR [was about encoding]

From: Prof Brian Ripley <ripley_at_stats.ox.ac.uk>
Date: Wed 10 May 2006 - 02:13:59 EST

On Tue, 9 May 2006, ronggui wrote:

> I use R 2.3.0 under windows.
>
>> Sys.getlocale()
> [1] "LC_COLLATE=Chinese_People's Republic of
> China.936;LC_CTYPE=Chinese_People's Republic of
> China.936;LC_MONETARY=Chinese_People's Republic of
> China.936;LC_NUMERIC=C;LC_TIME=Chinese_People's Republic of China.936"
>> localeToCharset()
> [1] "CP936"
>
> Now I want to use JGR,which uses UTF-8 encoding.
> So when I use save.image function to save something containg Chinese
> character with R,and then load into JGR, the Chinese character will
> not display correctly.Of course,I can use iconv to convert the
> character making it readable.But is there any better way to this?

Yes, use a better OS!

Otherwise, Windows has no concept of UTF-8 locales, so if JGR expects one, the problem is that JGR needs to do the conversions: it is R that is running natively and JGR which is `foreign' here.

-- 
Brian D. Ripley,                  ripley@stats.ox.ac.uk
Professor of Applied Statistics,  http://www.stats.ox.ac.uk/~ripley/
University of Oxford,             Tel:  +44 1865 272861 (self)
1 South Parks Road,                     +44 1865 272866 (PA)
Oxford OX1 3TG, UK                Fax:  +44 1865 272595

______________________________________________
R-help@stat.math.ethz.ch mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html
Received on Wed May 10 02:18:41 2006

Archive maintained by Robert King, hosted by the discipline of statistics at the University of Newcastle, Australia.
Archive generated by hypermail 2.1.8, at Wed 10 May 2006 - 04:09:59 EST.

Mailing list information is available at https://stat.ethz.ch/mailman/listinfo/r-help. Please read the posting guide before posting to the list.