On Mon, Jun 21, 2010 at 4:28 PM, Thaler, Thorn, LAUSANNE, Applied Mathematics <thorn.tha...@rdls.nestle.com> wrote: > Thanks, works as expected. But maybe I've to be a bit more clear about the > reason why I'd like to have such a construct. > > In lattice you can define some parameters by passing a named list to > par.settings. Suppose I want to superpose two lines and use colors different > from the default: > > xyplot(1:10~c(1:5,1:5), type="o", groups=rep(1:2,each=5), > par.settings=list(superpose.line=list(col=1:2), > superpose.symbol=list(col=1:2)))
Have you considered xyplot(1:10~c(1:5,1:5), type="o", groups=rep(1:2,each=5), par.settings= simpleTheme(col=1:2)) ? -Deepayan > I have to specify the same setting for superpose.line and superpose.symbol. > If I'd use your proposition, I've to hardcode the respective item names. It > is still an academic question, for there are thousands of ways to solve this > issue, but I was just curious whether it is possible to find an one-liner > without the need of specifying any temp variable. > > BR, Thorn [...] ______________________________________________ R-help@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.