[ncl-talk] need a shapefile out of attached (netcdf file) mask

Mary Haley haley at ucar.edu
Fri Jul 29 11:58:48 MDT 2016


Noah,

First, NCL doesn't have any tools for writing shapefile data.

Second, I'm a little confused by this request, because the shapefiles we
that we use in NCL are for geographical outlines, which means the X and Y
arrays on the shapefile correspond with longitude and latitude data. A
feature of shapefiles is that you can have "ragged arrays". That is, you
may have a geographical area that is represented by several distinct areas,
each one defined by an X/Y array of different lengths. The file you
provided only contains a 2D array filled with 0s and 1s, so I'm not sure
how you want this translated into shapefile data with geographic
information.

If you need to use this mask for computational or graphical purposes in
NCL, then you shouldn't need to translate it to anything. You should be
able to use it directly.  See the "mask" and "where" functions as a start:

http://www.ncl.ucar.edu/Document/Functions/Built-in/mask.shtml
http://www.ncl.ucar.edu/Document/Functions/Built-in/where.shtml

You may also want to see our "mask" examples page:

http://www.ncl.ucar.edu/Applications/mask.shtml

--Mary




--Mary

On Fri, Jul 29, 2016 at 1:29 AM, Kerandi, Noah Misati (IMK) <
noah.kerandi at kit.edu> wrote:

> Dear ncl users,
>
> I have a netcdf file (see attached) which i use as a mask. i need
> assistance to generate a shape file.
>
> Such assistance will be appreciated.
>
> Regards.
>
>
>
> Noah M. Kerandi
> KIT-Campus Alpin
> IMK-IFU: Atmospheric Environmental Research
> Kreuzeckbahnstr. 19,
> 82467 Garmisch-Partenkirchen
> Germany
>
> _______________________________________________
> 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/20160729/c107a3c4/attachment.html 


More information about the ncl-talk mailing list