Shading
Kevin M Levey
klevey at CUSTOMWEATHER.COM
Wed Nov 11 13:45:20 EST 2009
Hi Andy
cint (contour interval) only applies to contour lines, i.e. when you
set gxout contour
Shading intervals are set with
set clevs
see my example below:
Shading interval is determined by whatever you set up in your legend,
i.e. (this is an example gs file : my_legend.gs)
*light blue to dark blue
'set rgb 41 200 255 255'
'set rgb 42 175 240 255'
'set rgb 43 130 210 255'
'set rgb 44 95 190 250'
'set rgb 45 75 180 240'
'set rgb 46 60 170 230'
'set rgb 47 40 150 210'
'set rgb 48 30 140 200'
'set rgb 49 20 130 190'
'set rgb 50 20 120 180'
'set rgb 51 20 110 170'
*light pink to dark rose
'set rgb 61 255 230 230'
'set rgb 62 255 200 200'
'set rgb 63 248 160 160'
'set rgb 64 230 140 140'
'set rgb 65 230 112 112'
'set rgb 66 230 80 80'
'set rgb 67 200 60 60'
'set rgb 68 180 40 40'
'set rgb 69 164 32 32'
'set rgb 70 134 32 32'
'set rgb 71 104 32 32'
'set rgb 72 74 32 32'
'set grads off'
'set timelab on'
'set clevs -25 -22.5 -20 -17.5 -15 -12.5 -10 -7.5 -5 -2.5 0
2.5 5 7.5 10 12.5 15 17.5 20 22.5 25 '
'set ccols 51 50 49 48 47 46 45 44 43 42
41 62 63 64 65 66 67 68 69 70 71 72'
Here my shading interval is 2.5.
If you wanted to plot contours + shading then you'd simply make cint
2.5 as well.
set gxout shaded
d variable
set gxout contour
set cint 2.5
d variable
run my_legend.gs
You can define your own colors as I have above - you just need to know
what the rgb values are. the limitations usually come
If you don't "run my_legend.gs" or if you don't specify set clevs and
set ccols in your script, GRADS will use default colors and intervals
and it will change from plot to plot depending on what the max/min
values are. Using your own set colors and intervals will ensure the
same legend range is used for all plots.
Hope this helps.
Regards,
Kevin M Levey, MSc in Oceans and Atmospheric Sciences (University of
Cape Town)
Director of Meteorological Operations
CustomWeather, Inc.
San Francisco, California, USA
"Taking the World by Storm!"
http://www.customweather.com
http://www.myforecast.com
http://www.1stweather.com
cell: 415-794-0411
work: 415-777-3566
email: klevey at customweather.com
On Nov 11, 2009, at 11/11/09 - 9:03 AM, Andrew Revering wrote:
> In this example:
> http://portal.nccs.nasa.gov/cgi-d520_fp/geos5_wx.cgi
>
> The number of shade levels is ‘a lot’. So you get this look of
> something very fluid, and hard to see one color to the next.
>
> I tried to set cint to 1 in my map, and it does not seem to be
> contouring every 1 degree.
>
> Is this a limitation due to the number of defined colors (16) ? and
> when its set to 1 there are too many levels and not enough colors?
>
> Or is there something else I need to do so that I’m able to contour
> at a very frequent interval?
>
> Is there a way to have the default colors just circulate
> automatically… IE, when you go through all the colors have it just
> start over again, or is this done by default?
>
> Andy
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://gradsusr.org/pipermail/gradsusr/attachments/20091111/cc5e5ff0/attachment.html
More information about the gradsusr
mailing list