Re: inverting the label bar color spread

From: Mary Haley (haley@XXXXXX)
Date: Thu Jul 19 2001 - 13:54:42 MDT


>
> Dear NCL Users:
>
> I was wondering if there is an easy way to invert the label bar
> color spread. For example if I choose the gui default label bar
> for my color fill, the default color spread is blue to red or cool
> to warm. Is there a way to invert the color spread so that it
> goes from red to blue or warm to cool ? I have attempt using
> a combination of following resources;
>
> gsnSpreadColors = True
> gsnSpreadColorsStart =
> gsnSpreadColorsEnd =
>
> but I have yet to reverse the color scheme. Any suggestions
> would be greatly appreciated.
>
> Thank you,
> Matt

Hi Matt,

Currently, there is no way to do this using the three resources above,
but I will see what I can do about this.

Meanwhile, you might want to consider just "flipping" the color map.
You can do this yourself if you are pre-defining the color map as a
series of RGB values or named colors, or, you can retrieve the color
map that's currently in use, reverse it, and then reset it:

 cmap = gsn_retrieve_colormap(wks) ; Retrieve current color map.
 cmap(2:,:) = cmap(2::-1,:) ; Reverse all colors except
                                     ; foreground/background.
 gsn_define_colormap(wks,newcmap) ; Redefine new color map.

--Mary



This archive was generated by hypermail 2b29 : Tue Feb 19 2002 - 09:06:06 MST