[R] ASCII character set and hyphen
Roland Kaiser
roland.kaiser at sbg.ac.at
Mon Nov 19 17:47:53 CET 2007
Hi all!
To add to my previous posting
I want to give some more deatils give a more precise
I want to print a hyphen to a pdf() or postscript() device.
As the documentaion of postscript says
ASCII Character 45("-") is mapped to a minus sign (ASCII Character
95) by default.
The advice given is to use "\173" for a hyphen.
But, the following code produces a curly brace
instead of a hyphen.
Thanks for any advice?
Roland
library(rgr)
pdf("foo.pdf", encoding = "ISOLatin1")
display.ascii.d()
mtext("\173", side = 3)
dev.off()
R version 2.6.0 (2007-10-03)
i386-apple-darwin8.10.1
locale:
de_AT.UTF-8/de_AT.UTF-8/de_AT.UTF-8/C/de_AT.UTF-8/de_AT.UTF-8
attached base packages:
[1] stats graphics grDevices utils datasets methods base
other attached packages:
[1] rgr_1.0.3 MASS_7.2-36 akima_0.5-1
More information about the R-help
mailing list