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

Home » Public Forums » archive » 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
color shift between 2 contour plots? [message #58149] Tue, 22 January 2008 05:56
WRC2008 is currently offline  WRC2008
Messages: 14
Registered: September 2007
Junior Member
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=128
CTLoad, 3, /REVERSE, NCOLORS=128, BOTTOM=128

Maybe smaller question here: Is the above possible to create the same
colors, but without the white in the middle?

Now, I am plotting to contourplots in the same window, each from a
different dataset. I set the number of levels myself, by doing this:

mindiff = 990
nlv=17
levs=mindiff+findgen(nlv)*2.5

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. For example: the light blue band in
the first plot are values between 997.5 and 1000, while in the second
plot the same band has values between 1000 and 1002.5. This is the
case for all colors. This makes the comparison between the 2 plots
really misleading and erroneousness. Below the code how I plot the 2
contourplots:

map_set,/Cylindrical,/iso,/GRID,limit=LIMITS,/ADVANCE
contour, pres,lon,lat,/fill,/overplot, /noerase, LEVELS=levs
CONTOUR, pres,lon,lat,/follow,/overplot, /noerase,LEVELS=levs
map_continents,/continents,/countr,/ADVANCE
map_grid, /ADVANCE, Label=1, LATLAB=-17.5, CHARTHICK=1.3,
LATS=[80,70,60,50,40,30,20],
LATNAMES=['70°N','60°N','50°N','40°N','30°N', '20°N'],$
LONLAB=73, LONS=[-20,-10,0,10,20,30],
LONNAMES=['20°W','10°W','0°','10°E','20°E','30°E']

map_set,/Cylindrical,/iso,/GRID,limit=LIMITS,/ADVANCE
contour, pres1,lon1,lat1,/fill,/overplot, /noerase, LEVELS=levs
CONTOUR, pres1,lon1,lat1,/follow,/overplot, /noerase,LEVELS=levs
map_continents,/continents,/countr,/ADVANCE
map_grid, /ADVANCE, Label=1, LATLAB=-17.5, CHARTHICK=1.3,
LATS=[80,70,60,50,40,30,20],
LATNAMES=['70°N','60°N','50°N','40°N','30°N', '20°N'],$
LONLAB=73, LONS=[-20,-10,0,10,20,30],
LONNAMES=['20°W','10°W','0°','10°E','20°E','30°E']

Can somebody help me out with this???
Thank you!
  Switch to threaded view of this topic Create a new topic Submit Reply
Previous Topic: Re: Is there any way to change the dimension of a field in a structure?
Next Topic: Re: Is there any way to change the dimension of a field in a structure?

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

Current Time: Thu Oct 09 23:13:22 PDT 2025

Total time taken to generate the page: 0.96113 seconds