Re: [R] equal spacing of the polygons in levelplot key (lattice)

2011-11-16 Thread Andy Bunn
-Original Message- From: Dennis Murphy [mailto:djmu...@gmail.com] Sent: Tuesday, November 15, 2011 8:54 PM To: Andy Bunn Cc: r-help@r-project.org Subject: Re: [R] equal spacing of the polygons in levelplot key (lattice) Hi: Does this work? Thanks Dennis. This almost works

Re: [R] equal spacing of the polygons in levelplot key (lattice)

2011-11-16 Thread Dennis Murphy
: Re: [R] equal spacing of the polygons in levelplot key (lattice) Hi: Does this work? Thanks Dennis. This almost works. Is there a way to make the rectangles in the key the same size? In this example five rectangles of the same area evenly arrayed? Can the key be coerced into being

Re: [R] equal spacing of the polygons in levelplot key (lattice)

2011-11-16 Thread Andy Bunn
-Original Message- From: Dennis Murphy [mailto:djmu...@gmail.com] Sent: Wednesday, November 16, 2011 11:22 AM To: Andy Bunn Cc: r-help@r-project.org Subject: Re: [R] equal spacing of the polygons in levelplot key (lattice) OK, how about this instead? # library('lattice') levs

[R] equal spacing of the polygons in levelplot key (lattice)

2011-11-15 Thread Andy Bunn
Given the example: R (levs - quantile(volcano,c(0,0.1,0.5,0.9,0.99,1))) 0% 10% 50% 90% 99% 100% 94 100 124 170 189 195 R levelplot(volcano,at=levs) How can I make the key categorical with the size of the divisions equally spaced in the key? E.g., five equal size rectangles with

Re: [R] equal spacing of the polygons in levelplot key (lattice)

2011-11-15 Thread Dennis Murphy
Hi: Does this work? # library('lattice') levs - as.vector(quantile(volcano,c(0,0.1,0.5,0.9,0.99,1))) levelplot(volcano, at = levs, colorkey = list(labels = list(at = levs, labels = levs) )) HTH, Dennis On Tue, Nov 15, 2011 at 1:12