Re: [R] How to change col and pch between panels in xyplot

2008-05-17 Thread hadley wickham
On Sat, May 17, 2008 at 10:03 PM, Michael Kubovy <[EMAIL PROTECTED]> wrote: > Dear R-helpers, > > x <- rep(1:2, 4) > y <- c(2, 4, 3, 5, 1, 3, 2, 4) > w <- factor(rep(1:2, each = 4)) > v <- rep(1:2, each = 2, 2) > xyplot(y ~ x | w, groups = v, type = 'b') > > How do I tell xyplot to use four colors

[R] How to change col and pch between panels in xyplot

2008-05-17 Thread Michael Kubovy
Dear R-helpers, x <- rep(1:2, 4) y <- c(2, 4, 3, 5, 1, 3, 2, 4) w <- factor(rep(1:2, each = 4)) v <- rep(1:2, each = 2, 2) xyplot(y ~ x | w, groups = v, type = 'b') How do I tell xyplot to use four colors and four plot characters and four line types? And how do I set up an appropriate key in ea