Re: [R] how to close trellis.device?

From: Zhongming Yang <zhongmingyang_at_yahoo.com>
Date: Fri 18 Mar 2005 - 06:59:47 EST

 

Thank you for your post.
If I run:
trellis.dev(pdf, filename="junk.pdf')
plot(c(1:10))
dev.off()   

I get the correct junk.pdf.
But when I try to draw some fancy stuff using xyplot(...), then I just get a junk.pdf of 4kb only, and abode says ".. error, .. it has no page." If I remove dev.off(), then I can get correct junk.pdf after I close the R. Any thoughts?
If you really need my codes, I can post. But there are maybe too many things going on my codes.

Zhongming Yang

hadley wickham <h.wickham@gmail.com> wrote: Perhaps if you post the rest of the code you are using, we might be able to help - but trellis.dev(pdf, filename="'); ...; dev.off() certainly works for me.

Hadley

On Thu, 17 Mar 2005 07:57:44 -0800 (PST), Zhongming Yang wrote:
> Didn't save into pdf files. I am using R 2.01 on windows XP.
>
> Thanks
>
>
> hadley wickham wrote:
> What's wrong with dev.off()?
> Hadley
>
>
> On Thu, 17 Mar 2005 07:29:21 -0800 (PST), Zhongming Yang
> wrote:
> > Dear All:
> >
> > I need draw some figure through trellis.device and save them as pdf files.
> How can I close trellis.device (something like dev.off() in nonlattice
> figure)?
> >
> > Many thanks
> >
> > Zhongming Yang
> >
> > ---------------------------------
> >
> > [[alternative HTML version deleted]]
> >
> > ______________________________________________
> > 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
> >
>
>
> ________________________________
> Do you Yahoo!?

>
>
                


        [[alternative HTML version deleted]]



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 Fri Mar 18 07:04:34 2005

This archive was generated by hypermail 2.1.8 : Fri 03 Mar 2006 - 03:30:51 EST