[R] Passing arguments to gpar

Paul Murrell p.murrell at auckland.ac.nz
Sun Dec 6 21:44:08 CET 2009


Hi


Sebastien Bihorel wrote:
> Dear R-users,
> 
> I would like to know how to pass arguments to gpar() without hard-coding 
> them. I tried to store my arguments in a list and passed this list to 
> gpar(), but it did find the way to do it properly. Any help would be 
> appreciated.
> 
> a<- list(fontisze=8,col=3)
> gpar(fontsize=8,col=3)
> gpar(a)
> gpar(unlist(a))


Are you looking for this ... ?

do.call("gpar", a)

Paul


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

-- 
Dr Paul Murrell
Department of Statistics
The University of Auckland
Private Bag 92019
Auckland
New Zealand
64 9 3737599 x85392
paul at stat.auckland.ac.nz
http://www.stat.auckland.ac.nz/~paul/




More information about the R-help mailing list