[R] any way to set defaults for par?

jim holtman jholtman at gmail.com
Mon Jul 14 01:17:34 CEST 2008


One way that I do it is to save the default parameters with the
following statement in my profile:

assign('Default.par', par(no.readonly=T))

An then I have a function which will reset them:

plotReset <-
function()
{    # reset plotting window
    par(Default.par)
    windows(width=7.5,height=4.7, record=T, pointsize=10)
}


On Sun, Jul 13, 2008 at 6:31 PM, Carl Witthoft <carl at witthoft.com> wrote:
> I know how to set graphic parameters by calling par(), but what I'd like is
> a way to set the default values so that subsequent calls to par() use my
> defaults.  The reason to want this is that every time I create a new graphic
> window (I'm using quartz on OSX, and so far no answers in the Mac mailing
> list), my parameters get reset to the builtin defaults.
> I read about the "unexported variable .Pars," but would like to know if
> there's any way to manipulate that variable.
>
> thanks
> Carl
>
> ______________________________________________
> R-help at r-project.org mailing list
> https://stat.ethz.ch/mailman/listinfo/r-help
> PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
> and provide commented, minimal, self-contained, reproducible code.
>



-- 
Jim Holtman
Cincinnati, OH
+1 513 646 9390

What is the problem you are trying to solve?



More information about the R-help mailing list