[ncl-talk] Problem with contour plot

Mary Haley haley at ucar.edu
Mon Apr 17 15:02:08 MDT 2017


Guilherme,

Please see examples shapefiles_21.ncl at:

http://www.ncl.ucar.edu/Applications/shapefiles.shtml#ex21

It explains why you see these "blocky" contours in NCL.

Simply put, if you have four points that represent a box at the edge of a
domain, and three of them have data one them and one is missing, then NCL
will only draw contours in half of the box, because it won't extrapolate to
that missing point.

The real question is: do you simply want the graphics not to have gaps, or
do you actually want there to be data in locations that fall just outside
the geographical boundary?  You can do things to force values just outside
the geographical boundary, but this depends on how you are masking in the
first place.

If you are masking based on a shapefile, then see example shapefiles_18.ncl
on the same page:

http://www.ncl.ucar.edu/Applications/shapefiles.shtml#ex18

Note, however, that this mask is now returning values outside the range of
interest.

If you are simply trying to mask your data *graphically* by some
geographical area, then instead of trying to use a mask function, you can
draw the full data, and then draw polygons filled in with white in the
areas you don't want to see graphically.  That's what example 21 is showing.

--Mary


On Mon, Apr 17, 2017 at 1:00 PM, Guilherme Martins <jgmsantos at gmail.com>
wrote:

> Dear users,
>
> After searching extensively on the NCL website I was not able to find a
> solution to my problem. I only want values within the contour of the
> continent, but some edges appear in the figure that are stemming from the
> mask that I applied and I do not know how to remove this. The figure is
> attached for a better view of my problem.
>
> Best regards,
>
> Guilherme.
> --
> ------------------------------------------------------------
> ------------------------------------
> Instituto Nacional de Pesquisas Espaciais (INPE)
> Centro de Previsão de Tempo e Estudos Climáticos (CPTEC)
> Divisão de Satélites e Sistemas Ambientais (DSA)
> Programa de Monitoramento de Queimadas
> Telefone (INPE/CP): +55 12 3186-9205 <+55%2012%203186-9205> || Celular
> (TIM): +55 12 98111-4292 <+55%2012%2098111-4292>
> E-mail: guilherme.martins at inpe.br || jgmsantos at gmail.com
> Skype: guilherme.martins.
> Homepage: https://sites.google.com/site/jgmsantos
> Currículo Lattes: http://lattes.cnpq.br/5997657584785803
> ------------------------------------------------------------
> ------------------------------------
>
> _______________________________________________
> ncl-talk mailing list
> ncl-talk at ucar.edu
> List instructions, subscriber options, unsubscribe:
> http://mailman.ucar.edu/mailman/listinfo/ncl-talk
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://mailman.ucar.edu/pipermail/ncl-talk/attachments/20170417/96b2b947/attachment.html 


More information about the ncl-talk mailing list