Re: self defined colormap

From: David Brown (dbrown AT XXXXXX)
Date: Mon Aug 16 2004 - 12:14:57 MDT


Actually you do not necessarily need to put colormaps into
$NCARG_ROOT/lib/ncarg/colormaps.
There is an environment variable called NCARG_COLORMAP_PATH that allows
you to define
a colon-separated list of directories in which to look for colormaps.
NCL looks in all directories in the list for
files with the extensions ".rgb", ."gp" (the GIST colormap format), or
".ncmap" (the ncview colormap format).

The default value of NCARG_COLORMAP_PATH is
".:$NCARG_ROOT/lib/ncarg/colormaps" which means that it will look in
the current working directory and
in the standard colormap directory.

Unfortunately this capability has never documented up till now. I will
try to correct that omission soon.
  -Dave Brown

On Aug 16, 2004, at 9:08 AM, Mary Haley wrote:

>>
>> How can I define my own colormap, i.e. with a pre-defined color table.
>> Say, I want to use color table "BlWhRe", but I would like to add one
>> more white in between, does anybody know how to do it? Thanks.
>>
>> Liz
>>
>
> Hi Liz,
>
> Most of the colormaps available to NCL are ASCII files, and thus you
> can edit them and create new colormaps (or just change the existing
> ones.) The ones you can edit reside in the directory
> $NCARG_ROOT/lib/ncarg/colormaps.
>
> To add an extra white color to "BlWhRe":
>
> 1. Copy $NCARG_ROOT/lib/ncarg/colormaps/BlWhRe.rgb to
> a new file in the same directory. Call it
> something like "$NCARG_ROOT/lib/ncarg/colormaps/BlWhWhRe.rgb"
>
> 2. Edit this new file and find the white color you want to
> duplicate. I believe the one you are interested in is on
> line 53:
>
> 255 255 255
>
> Make a duplicate copy of this line.
>
> 3. You now have a new colormap, called "BlWhWhRe" that
> you can load from NCL.
>
> --Mary
>
> -------------------------------------------------
> Mary Haley haley AT ucar.edu
> NCAR/SCD/VETS 303-497-1254 (voice)
> 1850 Table Mesa Dr 303-497-1804 (fax)
> Boulder, CO 80305
> -------------------------------------------------
> _______________________________________________
> ncl-talk mailing list
> ncl-talk AT ucar.edu
> http://mailman.ucar.edu/mailman/listinfo/ncl-talk

_______________________________________________
ncl-talk mailing list
ncl-talk AT ucar.edu
http://mailman.ucar.edu/mailman/listinfo/ncl-talk



This archive was generated by hypermail 2b29 : Mon Aug 16 2004 - 13:11:28 MDT