Re: [R] xyplot, type="b"

From: Benjamin Tyner <btyner_at_gmail.com>
Date: Wed 21 Jun 2006 - 13:59:34 EST

I can imagine the intended effect of this, but for some reason it does not work as expected--the 'gaps' do not show up (I'm using 2.3.0). Also, I think it would have to be tweaked to prevent overlapping for points very close together. Incidentally, the benefit I seek is most pronounced with pch=".", as then one gets the best of both worlds.

Ben

Paul Murrell wrote:

>Is this what you mean ... ?
>
>dat<-data.frame(x=1:10,y=1:10,z=sample(letters[1:3],10,T))
>xyplot(y~x | z, data = dat,
> panel = function(x, y, ...) {
> panel.lines(x, y, ...)
> panel.points(x, y, col=trellis.par.get("background")$col,
> cex=1.5, pch=16, ...)
> panel.points(x, y, ...)
> })
>
>Paul
>



R-help@stat.math.ethz.ch mailing list
https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html Received on Wed Jun 21 15:14:56 2006

Archive maintained by Robert King, hosted by the discipline of statistics at the University of Newcastle, Australia.
Archive generated by hypermail 2.1.8, at Wed 21 Jun 2006 - 16:12:50 EST.

Mailing list information is available at https://stat.ethz.ch/mailman/listinfo/r-help. Please read the posting guide before posting to the list.