jtamir wrote:
> I am creating projections centered around various locations:
>
>
> m = Basemap(width=best_width, height=best_height, lon_0=centerLon
> lat_0=centerLat, resolution='c',area_thresh=10000.,projection='laea')
>
> For every location, i have the same code to fill the regions:
>  
> m.fillcontinents(color='#997766',lake_color='#99ffff',zorder=1)
>   
>> m.drawcoastlines(color='#000000', zorder=3)
>> m.drawcountries(color="0.75", zorder=2)
>> m.drawmapboundary(fill_color='#99ffff', zorder=0)
>>
>>     
> For most regions, this results in the expected plot (
> http://www.nabble.com/file/p23451317/good.png good.png )
> However, whenever the region includes South America/Antarctica,
> fillcontinents will color the entire map (
> http://www.nabble.com/file/p23451317/bad.png bad.png )
>
> Is this a known issue, and is there a way to circumvent it?
>
> Thanks,
> Jon
>
>   
Jon: It's a know issue. From the KNOWN_BUGS file:
* The fillcontinents method doesn't always do the right thing.  Matplotlib
always tries to fill the inside of a polygon.  Under certain situations,
what is the inside of a coastline polygon can be ambiguous, and the
outside may be filled instead of the inside.  To trigger this,
run the garp.py example with lon=-71,lat=-33 (Santiago, Chile).
Workaround - mask the land areas with the drawlsmask method instead of
filling the coastline polygons.
-Jeff
-- 
Jeffrey S. Whitaker         Phone  : (303)497-6313
Meteorologist               FAX    : (303)497-6449
NOAA/OAR/PSD  R/PSD1        Email  : Jef...@no...
325 Broadway                Office : Skaggs Research Cntr 1D-113
Boulder, CO, USA 80303-3328 Web    : http://tinyurl.com/5telg
  |