[R] dev.print in R 1.7.1

Prof Brian Ripley ripley at stats.ox.ac.uk
Mon Oct 20 13:29:10 CEST 2003


I can't help you with 1.7.1: it is obselete.  But since you are apparently
using Windows, there are menus in 1.8.0 to do what you want, as well as
the command savePlot() (AFAIK there never was a function save.plot).

On Mon, 20 Oct 2003, Kim Mouridsen wrote:

> Dear R experts
> 
>  
> 
> How do I save a plot to a file in a specified format, f.ex ’png’?
> 
>  
> 
> Apparently ’save.plot’ no longer exists, so I tried instead
> 
>  
> 
> dev.print(file="H:\\jesperf\\data1image",device=png())

That should be device=png, not png(), as the help page says.

> However no file is created and – much worse – no graphics is produced
> (on screen or file) if I run
> 
> f.ex qqnorm afterwards.

Try dev.list() and dev.off()?

> What am I doing wrong and how do I get R to print graphics on the screen
> as ususal?

-- 
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