[R] How can I save a plot ?

John Wiedenhoeft john at nurfuerspam.de
Wed Nov 21 21:56:36 CET 2007


Try something like:

pdf(file="filename.pdf")
plot(...)
dev.off();

works with other formats as well. Type ?Devices

Hope that helps,
John

On Wednesday 21 November 2007 21:45:38 Maura E Monville wrote:
> I recently installed R 2.6 on Linux/SuSE
> When I was running the previous version on Windows I was able to save my
> plots from a script.
> There was a command "savePlot" that is no more retrieved in the last
> version.
> In this scenario, how can I tell R to save the currently displayed plot to
> a file ?
> The "save" command is generic and do not know how to tell R that the plot
> is to be saved using this command.
>
> In addition, is it possible with R to have more than one plot, that is more
> than one graphic window opened at the same time ?
>
> Thank you so much.
>
> Regards,



More information about the R-help mailing list