[R] embedFonts rotates figure
Paul Smith
phhs80 at gmail.com
Tue Oct 9 01:02:40 CEST 2007
On 10/8/07, Prof Brian Ripley <ripley at stats.ox.ac.uk> wrote:
> >> Consider the following code:
> >>
> >> pdf(file="figure.pdf",family="URWPalladio")
> >>
> >> curve(dlnorm(x,0,1.5),0,10,xlim=c(0,10),ylim=c(0,0.85),axes=F,xlab="",ylab="f")
> >> segments(exp(-1.5^2),0,exp(-1.5^2),dlnorm(exp(-1.5^2),0,1.5),lty="dashed")
> >> segments(1,0,1,dlnorm(1,0,1.5),lty="dashed")
> >> segments(exp(1.5^2),0,exp(1.5^2),dlnorm(exp(1.5^2),0,1.5),lty="dashed")
> >> axis(2)
> >> axis(1,at=c(exp(-1.5^2),1,exp(1.5^2)),labels=c(expression(mu[0]),expression(mu[e]),expression(mu)))
> >> box()
> >>
> >> dev.off()
> >>
> >> and now:
> >>
> >> embedFonts("figure.pdf")
> >>
> >> The figure.pdf gets rotated. Any ideas about how to prevent the
> >> rotation? I am using R 2.5.1 on F7 (Linux).
> >>
> >>
> > embedFonts("figure.pdf", options="-dAutoRotatePages=/None")
> >
> > Or stick the same thing into the environment variable GS_OPTIONS and
> > begone with the autorotation misfeature for good. (As far as I remember,
> > this is neither the fault of R nor Ghostscript.)
>
> It comes from recentish versions of Ghostscript following Adobe. See
>
> https://www.stat.math.ethz.ch/pipermail/r-devel/2003-October/027766.html
> http://finzi.psych.upenn.edu/R/Rhelp02a/archive/26598.html
Thanks to both for having helped me with such an intriguing problem.
Paul
More information about the R-help
mailing list