Re: [R] Plotting multiple xyplots in same page

2013-02-14 Thread Duncan Mackay
nt(xy, pos = c(0.66, 0.0, 0.99, 0.5), more = FALSE) Pascal: I would prefer not to use panels as this is for publication purpose. Many thanks, Lisa - Original Message - From: Duncan Mackay To: Lisa Daniel ; r-help-r-project.org Cc: Sent: Wednesday, February 13, 2013 7:53 PM Subject: Re

Re: [R] Plotting multiple xyplots in same page

2013-02-13 Thread Lisa Daniel
anels as this is for publication purpose.  Many thanks, Lisa - Original Message - From: Duncan Mackay To: Lisa Daniel ; r-help-r-project.org Cc: Sent: Wednesday, February 13, 2013 7:53 PM Subject: Re: [R] Plotting multiple xyplots in same page Hi Lisa have a look at par.settings in

Re: [R] Plotting multiple xyplots in same page

2013-02-13 Thread Lisa Daniel
(xy, pos = c(0.33, 0.0, 0.66, 0.5), more = TRUE) j=j+1 print(xy, pos = c(0.66, 0.0, 0.99, 0.5), more = FALSE) Also, I would like to create a main title for the first row and second row of figures. Many thanks in advance, Lisa - Original Message - From: Duncan Mackay To: Lisa Daniel ;

Re: [R] Plotting multiple xyplots in same page

2013-02-13 Thread Pascal Oettli
Hello, Herewith is one approach: grid1 <- rbind(OrchardSprays, OrchardSprays, OrchardSprays, OrchardSprays, OrchardSprays, OrchardSprays) grid1$category <- rep(c('A','B','C','D','E','F'), each=nrow(OrchardSprays)) trellis.par.set(theme = col.whitebg()) xy <- xyplot(decrease ~ treatment | cat

Re: [R] Plotting multiple xyplots in same page

2013-02-13 Thread Duncan Mackay
Hi Lisa have a look at par.settings in ?xyplot trellis.par.get() shows the settings trellis.par.get()[[27]] $left $left$tck [1] 1 $left$pad1 [1] 1 $left$pad2 [1] 1 $top $top$tck [1] 1 $top$pad1 [1] 1 $top$pad2 [1] 1 $right $right$tck [1] 1 $right$pad1 [1] 1 $right$pad2 [1] 1 $bottom

Re: [R] Plotting multiple xyplots in same page

2013-02-13 Thread Duncan Mackay
Hi Lisa You can use the page function of xyplot to do this xy <- xyplot(decrease ~ treatment, OrchardSprays, groups = rowpos, type = "a", page = function(n){ grid.text(LETTERS[j], y = 0.95, x = 0.01,

Re: [R] Plotting multiple xyplots in same page

2013-02-13 Thread Lisa Daniel
Dear Rhelp, I was able to plot 6 figures in one page.  I do need help in reducing the space between the title and the plot and assigning A,B,C,D,E,F to each figure library(lattice) trellis.par.set(theme = col.whitebg()) xy <- xyplot(decrease ~ treatment, OrchardSprays,         main="Some plot",  

[R] Plotting multiple xyplots in same page

2013-02-13 Thread Lisa Daniel
Dear Rhelp, I would like to have 6 xyplots in the same page.  Similar to (par(mfrow=c(3,3)) Found this example on the R archives. library(lattice) trellis.par.set(theme = col.whitebg()) xy <- xyplot(decrease ~ treatment, OrchardSprays,   groups = rowpos, type = "a",   auto.