Skip to content

Dont print plot on screen

4 messages · Joel, Duncan Murdoch, jim holtman +1 more

#
Hi is there any command or setting that allows you to do the plot command but
it dose not print the plot on screen?

So when you are saveing an plot in a function you dont want it to display
the plot just save it.
#
On 08/12/2010 8:14 AM, Joel wrote:
Yes, that's the normal behaviour when plotting to a file.  Just open a 
device in the output format you want.  For example,

pdf(file="example.pdf")
plot(rnorm(100))
dev.off()


Duncan Murdoch
#
The create a file with the graphics:

?pdf
?jpg
?postscript

The question is if you are generating it, what do you want to do with
it.  If you don't say otherwise, it will go to the default graphics
which is probably a window on your console.  You will have to direct
it where you want it.
On Wed, Dec 8, 2010 at 8:14 AM, Joel <joda2457 at student.uu.se> wrote:

  
    
#
For (at least) boxplot() and hist(), you can set plot=FALSE
But since we don't know what type of plot you want, difficult to be sure.
Ivan

Le 12/8/2010 14:14, Joel a ?crit :