Re: [R] Adding units to levelplot's colorkey

2011-11-23 Thread Carlisle Thacker
Thanks. On 11/23/11 2:20 AM, Deepayan Sarkar wrote: On Tue, Nov 15, 2011 at 6:53 PM, Carlisle Thacker carlisle.thac...@noaa.gov wrote: Sorry that I was not clear. I was asking how to add annotation to levelplot's colorkey, not the levelplot itself. The only entry I can find from the help

Re: [R] Adding units to levelplot's colorkey

2011-11-23 Thread Carlisle Thacker
Here is an example with what I've been able to manage for a vertical colorkey: library(lattice)# make levelplot available library(openair) # make drawOpenKey available # construct data x = 1:10 y = rep(x,rep(10,10)) x = rep(x,rep(10)) z = x+y # in centimeters # try work-around,

Re: [R] Adding units to levelplot's colorkey

2011-11-22 Thread Deepayan Sarkar
On Tue, Nov 15, 2011 at 6:53 PM, Carlisle Thacker carlisle.thac...@noaa.gov wrote: Sorry that I was not clear.  I was asking how to add annotation to levelplot's colorkey, not the levelplot itself.  The only entry I can find from the help pages is via its labels. Googling did yield this:  

Re: [R] Adding units to levelplot's colorkey

2011-11-15 Thread David Winsemius
On Nov 14, 2011, at 7:20 PM, Carlisle Thacker wrote: Thanks, Dennis. Yes, I can do that, but that locks the physical units to locations of the labels. I had hoped that there might be something a bit more flexible, like a subtitle or more general text. If you would take the time to

Re: [R] Adding units to levelplot's colorkey

2011-11-15 Thread David Winsemius
On Nov 15, 2011, at 8:23 AM, Carlisle Thacker wrote: Sorry that I was not clear. I was asking how to add annotation to levelplot's colorkey, not the levelplot itself. The only entry I can find from the help pages is via its labels. Googling did yield this: draw.colorkey() doesn't

Re: [R] Adding units to levelplot's colorkey

2011-11-15 Thread Carlisle Thacker
Sorry that I was not clear. I was asking how to add annotation to levelplot's colorkey, not the levelplot itself. The only entry I can find from the help pages is via its labels. Googling did yield this: draw.colorkey() doesn't support a title for the legend. So I presume there is also no

Re: [R] Adding units to levelplot's colorkey

2011-11-14 Thread Dennis Murphy
You don't show code or a reproducible example, so I guess you want a general answer. Use the draw.colorkey() function inside the levelplot() call. It takes an argument key =, which accepts a list of arguments, including space, col, at, labels, tick.number, width and height (see p. 155 of the

Re: [R] Adding units to levelplot's colorkey

2011-11-14 Thread Carlisle Thacker
Thanks, Dennis. Yes, I can do that, but that locks the physical units to locations of the labels. I had hoped that there might be something a bit more flexible, like a subtitle or more general text. Carlisle On 11/14/11 6:03 PM, Dennis Murphy wrote: You don't show code or a reproducible