Good day.
I’m a new comer in GRASS GIS and I would like to create a color table for my raster DEMs using my own colors and specifying the altitudes (in meters) for them. I created one by editing the srtm table but the colors are blended and I want them clearly separated. Is it possible ?
Eric Gaba wrote:
I'm a new comer in GRASS GIS and I would like to create a color table
for my raster DEMs using my own colors and specifying the altitudes (in
meters) for them. I created one by editing the srtm table but the
colors are blended and I want them clearly separated. Is it possible ?
yes, just repeat the elevation twice:
GRASS> r.colors elevation.dem color=rules
Enter rules, "end" when done, "help" if you need it.
Data range is 1066 to 1840
1000 blue
1200 blue
1200 cyan
1400 cyan
1400 yellow
1600 yellow
1600 red
1800 red
1800 white
2000 white
end
d.rast elevation.dem
d.legend -f elevation.dem use=1100,1300,1500,1700,1900 range=1000,2000
more stuff here:
http://hamish.bowman.googlepages.com/grass_color_maps
http://trac.osgeo.org/grass/browser/grass-addons/raster/r.colors.tools
Hamish
____________________________________________________________________________________
Be a better friend, newshound, and
know-it-all with Yahoo! Mobile. Try it now. http://mobile.yahoo.com/;_ylt=Ahu06i62sR8HDtDypao8Wcj9tAcJ
I wrote:
d.legend -f elevation.dem use=1100,1300,1500,1700,1900 range=1000,2000
for a cat (interger aka CELL) map you can assign each of the use= values
a label like "1000-2000m" with the r.category or r.support modules. The
Use the 'd.legend -c' flag to hide the midpoint number and just show the
label.
I think this used to work for FP (floating point aka FCELL or DCELL) maps
too, but is currently broken. I've been meaning to look into that.
Hamish
____________________________________________________________________________________
Be a better friend, newshound, and
know-it-all with Yahoo! Mobile. Try it now. http://mobile.yahoo.com/;_ylt=Ahu06i62sR8HDtDypao8Wcj9tAcJ
Perfect ! That's what I was looking for. Thank you very much for this fast answer.
I didn't understand everything you wrote, but I edited my text type color table by repeating the elevations. With my FP GeoTiff map made from several SRTM3 tiles, using r.colors and specifying my customized color table, it works the way I want. Thanks again.
Eric
I wrote:
d.legend -f elevation.dem use=1100,1300,1500,1700,1900 range=1000,2000
for a cat (interger aka CELL) map you can assign each of the use= values
a label like "1000-2000m" with the r.category or r.support modules. The
Use the 'd.legend -c' flag to hide the midpoint number and just show the
label.I think this used to work for FP (floating point aka FCELL or DCELL) maps
too, but is currently broken. I've been meaning to look into that.Hamish