[R] Error in PDF output in R 2.0.0

Deepayan Sarkar deepayan at stat.wisc.edu
Fri Oct 29 18:25:24 CEST 2004


On Fri, 29 Oct 2004 james.holtman at convergys.com wrote:

>
> The following script works fine in R 1.9.1.  It was creating a PDF file
> with the graphs in it.  In R 2.0.0, I got the error message below.  I tried
> the same script just outputting to Windows and postscript and the output
> was OK.  The error message only showed up when trying to create a PDF file.

[...]

> ## output to PDF file  --  ERRORS
> > pdf('out.pdf')
> > print(xyplot(I(usr/sys) ~ time|factor(cpu), memIn,
> +     panel=function(x,y)panel.xyplot(x,y,type='l')))
> Error in "[<-"(`*tmp*`, pos.heights[[nm]], value = numeric(0)) :
>         nothing to replace with
> > print(xyplot(csw ~ time|factor(cpu), memIn,
> +     panel=function(x,y)panel.xyplot(x,y,type='l')))
> Error in "[<-"(`*tmp*`, pos.heights[[nm]], value = numeric(0)) :
>         nothing to replace with
> > dev.off()
> windows
>       2

This is not reproducible, and I didn't see an error with similar code
(with different data) in a fresh session. Are you sure this is all you
did? Didn't you have a call to trellis.par.set / lset somewhere in
between?

There is a bug involved, and it has already been reported, and a
workaround posted. I'll upload a new version of lattice which fixes this
in a couple of days.

Deepayan




More information about the R-help mailing list