[R] problem with postcript() and umlauts

Prof Brian Ripley ripley at stats.ox.ac.uk
Mon Jun 27 18:38:01 CEST 2005


That's the first time I have heard ß called an umlaut!

This sounds like an encoding problem, perhaps using Latin-1 in a UTF-8 
locale or vice versa.  In particular, R 2.0.1 (there is no 2.01) is out of 
date and has far less support for non-English locales than 2.1.1, and none 
for UTF-8 locales (which I believe SuSE 9.x uses by default).

So please follow the advice in the posting guide and update your R.
Your example works for me in 2.1.1 in both Latin-1 and UTF-8 locales.

Your email has been re-encoded several times en route to me, and does not 
contain character 142 (which is not a valid char in Latin-1 or UTF-8).

On Mon, 27 Jun 2005, Henning Rust wrote:

> Hello,
> I am running R 2.01 on SuSE 9.2 and I use GNU-Emacs and ESS.
> When using umlauts like ä ö ü ß for e.g. plot titles , I enter them
> directly in the code, like
>
> plot(seq(from=-4,to=4,length=100),dnorm(seq(from=-4,to=4,length=100)),
        main="Gauß-Verteilung")
>
> I get a dotted box just after the "Gau" and before the "ß" in the title.
>
> Using the postscript device
>
> postscript()
> plot(seq(from=-4,to=4,length=100),dnorm(seq(from=-4,to=4,length=100)),main="Gauß-Verteilung")
> dev.off()
>
> I get two warning messages:
>
> Warning messages:
> 1: font width unknown for character 142
> 2: font width unknown for character 142
> and a space after the "Gau" and before the "ß".
>
> I'd like to get rid of the extra space and the box before umlauts.
> Does anyone know how to solve the problem?


-- 
Brian D. Ripley,                  ripley at 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


More information about the R-help mailing list