[GRASSLIST:9800] Re: floating-point colorbar in ps.map

I am using Grass6.0

This is the colortable command:
#______________________Raster Map
raster masked_mx
    colortable y
    where 0.5 0.5
    height 2
    fontsize 10
    end

Here is the r.info results:

r.info map=masked_mx
+----------------------------------------------------------------------------+
| Layer: masked_mx Date: Fri Jan 6 16:35:21 2006 |
| Mapset: 1000N Login of Creator: mike |
| Location: GrassCrossSect |
| DataBase: /home/mike/projects/Chignik_Weasel |
| Title: ( test_mx4 ) |
|----------------------------------------------------------------------------|
| |
| Type of Map: raster Number of Categories: 255 |
| Data Type: FCELL |
| Rows: 380 |
| Columns: 900 |
| Total Cells: 342000 |
| Projection: UTM (zone 0) |
| N: 250 S: -130 Res: 1 |
| E: 1800 W: 900 Res: 1 |
| Range of data: min = 29.565027 max = 103.208115 |
| |
| Data Source: |
| vector file test_s1 |
| |
| |
| Data Description: |
| generated by v.surf.rst |
| |
| Comments: |
| tension=100.000000, smoothing=1.500000 |
| dnorm=863.770803, dmin=0.500000, zmult=1.000000 |
| segmax=40, npmin=44, rmsdevi=17.001548 |
| zmin_data=23.290000, zmax_data=117.610000 |
| zmin_int=29.565027, zmax_int=103.208114 |
| k |
| |
+----------------------------------------------------------------------------+

what is your ps.map input file syntax

what does r.info say about your raster

which Grass version?

Maciek

On wto, 2006-01-10 at 16:01 -0800, michaelp@sjgeophysics.com wrote:
> Hi Everyone,
>
> I am trying to add a colorbar with a color gradient to my ps.map
> instructions. My raster file is of type floating-point, and when I use
> the d.legend command I get a nice, smooth colorbar. How do I create the
> same type of colorbar in ps.map? If I try to use the colortable command
> in my ps.map script, all I get is:
>
> GRASS_INFO_WARNING(8431,1): Your cats/ file is invalid. A cats/ file with
> categories and labels is required for 'colortable' when using CELL
> rasters. No colortable will be assigned to this output postscript file.
>
> My cats file for this raster is as follows:
>
> # 255 categories
>
> 0.00 0.00 0.00 0.00
>
> Any help appreciated.
> Thanks, Mike.
>

--------------------
Szukasz do¶wiadczonej firmy poligraficznej? Zale¿y Ci na terminowo¶ci i atrakcyjnych
cenach?
Zapraszamy do nas!
http://www.foldruk.pl/

> I am trying to add a colorbar with a color gradient to my ps.map
> instructions. My raster file is of type floating-point, and when I use
> the d.legend command I get a nice, smooth colorbar. How do I create the
> same type of colorbar in ps.map? If I try to use the colortable command
> in my ps.map script, all I get is:
>
> GRASS_INFO_WARNING(8431,1): Your cats/ file is invalid. A cats/ file with
> categories and labels is required for 'colortable' when using CELL
> rasters. No colortable will be assigned to this output postscript file.
>
> My cats file for this raster is as follows:
>
> # 255 categories
>
>
>
>
>
> 0.00 0.00 0.00 0.00

You should only see that warning when using a CELL raster; FCELL and DCELL
rasters should trigger a floating point (smooth) legend. For category based
maps (CELL) only labeled categories will be displayed (r.support or edit that
cats file by hand/see spearfish soils), hence the warning if none are found.

There may be a bug here of course; but I have been using ps.map with both kinds
of maps without problems.

raster masked_mx
   colortable y
   where 0.5 0.5
   height 2
   fontsize 10
   end

I think you need a final "end" too?

I'm mostly away or busy with work until late Feb, so can't look into it much
before then. If you become convinced it is a bug, please file a bug report in
the GRASS bugtracker so it is lost in the noise & I'll look into it when I can.

note you can use a different raster for the colortable legend and what is
actually displayed with the "raster" instruction.
If omitted, it should use the map you specified with the previously called
"raster" instruction.

happy 2006,
Hamish

__________________________________________________
Do You Yahoo!?
Tired of spam? Yahoo! Mail has the best spam protection around
http://mail.yahoo.com