[GRASSLIST:386] Re: Legends

Soil & Water Lab. swlab at cornell.edu
Sat Jun 14 16:58:31 EDT 2003


Hamish
> > d.legend takes the color from the map. If the color doesn't exist in the
> > map, d.legend can't know what to use. I think it is a bad idea to have
> > d.legend try and extrapolate a color value or read directly from the
> > colr file and re-implement existing library functions. 

Glynn
> However, I'm not sure whether that is actually the right approach.
> It's arguable that there should be some notion of the "total" range,
> distinct from the range of values which actually occur.

David
> When doing a comparison between a series of maps (say temperature) it is
> important that the color for a given temperature remain the same
> throughout the whole series no matter what the range of individual maps
> might be.  Is this possible?

Seems that Glynn , David and I are thinking about the same thing: there should 
be the possibility to display a smooth legend from a given minimum to a given 
maximum, provided that the min and max values of the current map fall in the 
legend range, that a color table has been defined, and the user-defined 
extrema are covered by the colortable. That's just a matter of taking the 
extrema from the colortable, not from the map. Anyway, if there are some 
cells falling outside the colortable range, they are not displayed, and the 
legend is not affected.

Right now, the trick seems to define a temporary map (TMP), with some cells 
set to the "absolute" minimum, some others to the "absolute" maximum, with 
the same colortable as wanted for the other maps. Instead of displaying the 
current map legend, one displays the TMP legend instead... 

P.



-- 
------------------------------
Soil and Water Laboratory
Biological and Environmental Engineering Department
Cornell University
Riley-Robb Hall
ITHACA, NY 14853 - USA




More information about the grass-user mailing list