comp.lang.idl-pvwave archive
Messages from Usenet group comp.lang.idl-pvwave, compiled by Paulo Penteado

Home » Public Forums » archive » Re: color shift between 2 contour plots?
Show: Today's Messages :: Show Polls :: Message Navigator
E-mail to friend 
Switch to threaded view of this topic Create a new topic Submit Reply
Re: color shift between 2 contour plots? [message #58129] Tue, 22 January 2008 11:49 Go to next message
David Fanning is currently offline  David Fanning
Messages: 11724
Registered: August 2001
Senior Member
WRC2008@gmail.com writes:

> In my previous posts, I have asked some questions on how to create
> blue-white-red color table. This was answered by David, and now I use
> the following description to create this table:
>
> CTLoad, 1, NCOLORS=3D128
> CTLoad, 3, /REVERSE, NCOLORS=3D128, BOTTOM=3D128
>
> Maybe smaller question here: Is the above possible to create the same
> colors, but without the white in the middle?

ctload, 1, clip=[10,235], ncolors=128
ctload, 3, clip=[10, 235], /reverse, ncolors=128, bottom=128

> Now, the odd thing is, that the colors in the second plot are shifted
> one value compared to the first contourplot, although I use the same
> number of levels for both plots.

You don't want to use FILL, with map projections you HAVE to
use CELL_FILL, or you have these color problems:

http://www.dfanning.com/color_tips/fill_colors.html

Cheers,

David
--
David Fanning, Ph.D.
Fanning Software Consulting, Inc.
Coyote's Guide to IDL Programming (www.dfanning.com)
Sepore ma de ni thui. ("Perhaps thou speakest truth.")
Re: color shift between 2 contour plots? [message #58258 is a reply to message #58129] Wed, 23 January 2008 04:47 Go to previous message
WRC2008 is currently offline  WRC2008
Messages: 14
Registered: September 2007
Junior Member
YES!! This cell_fill does the trick, my plots look great now!
And I introduced the blue-red colortable for the absolute values, and
the blue-white-red for the difference values...

Just one more fact (again, as also posted in another topic....). My
background color changed again.
Although I define the blue-white-red color table just before putting !
P.BACKGROUND = 128, checking the 128 color with the cindex tool (being
white!!), I get a salmon color background, and by no means I can
change it to white. I can change it to all other colors I want (black,
blue, red,...) but no white....I am getting a bit desperate with the
colors here, so I hope someone can help me out!!!

The 2 defined color schemes, as suggested by David:

; blue - red
ctload, 1, clip=[10,235], ncolors=128
ctload, 3, clip=[10,235], /reverse, ncolors=128, bottom=128

;blue - white - red
CTLoad, 1, NCOLORS=128
CTLoad, 3, /REVERSE, NCOLORS=128, BOTTOM=128

THANKS!
  Switch to threaded view of this topic Create a new topic Submit Reply
Previous Topic: stop behavior
Next Topic: Re: idl 7.0 eclipse plugins and updates

-=] Back to Top [=-
[ Syndicate this forum (XML) ] [ RSS ] [ PDF ]

Current Time: Wed Oct 08 15:16:14 PDT 2025

Total time taken to generate the page: 0.00479 seconds