Re: Control on distinct colors for categories

From: Kyle Griffin <ksgriffin2_at_nyahnyahspammersnyahnyah>
Date: Thu Jun 12 2014 - 09:45:42 MDT

If you want to pick out colors without needing to grep for them, you can
always look at the alphabetical plots at

http://www.ncl.ucar.edu/Document/Graphics/named_colors.shtml

You can see many of the colors from the page, click on each icon to see the
specific names of the colors when you find something close to what you
want. It is alphabetized such that the colors starting with 'a' are in the
top left and proceed across the page and the down to the next row.

I think this is a bit more useful when choosing colors than Rick's
name-only method, but it could still be improved by some sort of RGB
ordering of the named colors.

Of course, your other alternative is always to just name the RGB pairs
yourself.

Hope this helped a bit...


Kyle

----------------------------------------
Kyle S. Griffin
Department of Atmospheric and Oceanic Sciences
University of Wisconsin - Madison
Room 1421
1225 W Dayton St, Madison, WI 53706
Email: ksgriffin2@wisc.edu


On Thu, Jun 12, 2014 at 10:35 AM, Rick Brownrigg <brownrig@ucar.edu> wrote:

> Hi Freddie,
>
> Two things going on:
>
> 1) the docs for cnFillPalette state that it is a new resource with NCL
> v.6.1.0, hence that warning message.
>
> 2) those three colors are not in NCL's named colors database. I don't
> know of a good way of telling what colors *are* in the database, other th=
an
> a hackish grep; for example, what shades of brown are available:
>
> cd $NCARG_ROOT/lib/ncarg/database
> grep -i brown rgb.*
>
> However, I'm surprised the plot would be blank in the face of those three
> warnings; perhaps something else is going on.
>
> I hope that helps...
> Rick
>
>
>
> On Thu, Jun 12, 2014 at 8:29 AM, <Freddie.Mpelasoka@csiro.au> wrote:
>
>>
>>
>>
>>
>> *From:* Mpelasoka, Freddie (CLW, Black Mountain)
>> *Sent:* Friday, 13 June 2014 12:23 AM
>> *To:* ncl-talk@ucar.edu
>> *Subject:* Control on distinct colors for categories
>>
>>
>>
>> Dear All,
>>
>>
>>
>> I am creating a plot using distinct colors for categorical data. I
>> adopted a script to do this, apparently the script does not use my color
>> scheme, but produces colors probably using a default colormap. I really
>> need to have control of colors so that I can have desired contrast betwe=
en
>> neighbouring polygons/regions. I will be grateful for your help. I have
>> attached my script, for your perusal.
>>
>>
>>
>> When I use ncl/6.0.0 I get “ warning:cnFillPalette is not a va=
lid
>> resource in BasinsLocation_contour at this time”
>>
>> When I use ncl/6.2.0 I get a blank output, with :
>>
>> warning:CvtStringGenArrayToCmap:Unable to find rgb of "lightgreen", usin=
g
>> white
>>
>> warning:CvtStringGenArrayToCmap:Unable to find rgb of "darkblue", using
>> white
>>
>> warning:CvtStringGenArrayToCmap:Unable to find rgb of "darkbrown", using
>> white
>>
>>
>>
>>
>>
>> Cheers, Freddie
>>
>>
>>
>> _______________________________________________
>> ncl-talk mailing list
>> List instructions, subscriber options, unsubscribe:
>> http://mailman.ucar.edu/mailman/listinfo/ncl-talk
>>
>>
>
> _______________________________________________
> ncl-talk mailing list
> List instructions, subscriber options, unsubscribe:
> http://mailman.ucar.edu/mailman/listinfo/ncl-talk
>
>

Received on Thu Jun 12 03:46:15 2014

This archive was generated by hypermail 2.1.8 : Wed Jul 23 2014 - 15:33:46 MDT