[R] How do I change which R Graphics Device is active?

Barry Rowlingson b.rowlingson at lancaster.ac.uk
Tue Jun 30 21:12:04 CEST 2009


On Tue, Jun 30, 2009 at 8:05 PM, Mark Knecht<markknecht at gmail.com> wrote:

> You could wrap it in a function of your own making, right?
>
> AddNewDev = function() {dev.new();AddNewDev=dev.cur()}
>
> histPlot=AddNewDev()
>
> Seems to work.

 You leaRn fast :) Probably better style is:

 newDev = function(){dev.new();return(dev.cur())}

 - which returns the value explicitly with return().

Barry




More information about the R-help mailing list