[ncl-talk] Overlay point shapefile on a plot

Lyndon Mark Olaguera olagueralyndonmark429 at gmail.com
Sun Jul 2 20:37:16 MDT 2017


Dear NCL experts,

I am trying to add point shapefile to a plot using the
gsn_add_shapefile_polymarkers function in NCL.

To view the contents of the shapefile I used the shape_utils.ncl from the
following link:


*https://www.ncl.ucar.edu/Applications/shapefiles.shtml
<https://www.ncl.ucar.edu/Applications/shapefiles.shtml>*

I tried to plot the shapefile in GIS and it works fine but I still got an
error that the geometry attribute should be a point when I plot it in NCL.
I am not sure why in the filedump below, the geometry type is "unknown".


I attached my script and the files that I am plotting.


Variable: a
Type: file
File path: may_hgt-hgt_1996-2012_850hPa.nc
Number of global attributes: 0
Number of dimensions: 2
Number of variables: 6
(0) ======================================================================
(0) Filename: "sig_regpval_1996-2012.shp"
(0)   Geometry type: unknown
(0)   # of features: 2906
(0)   Min/max lat:    -80.00/  82.50
(0)   Min/max lon:      0.00/ 360.00
(0)   Variable names and their types:
(0)       geometry : integer
(0)       segments : integer
(0)       x : double
(0)       y : double
(0)       z : double
(0)       CREATED_BY : string
(0)       AUTHOR : string
(0)       TYPE : string
(0)       DESC : string
(0)       LONGITUDE : double
(0)       LATITUDE : double
(0)       GRID_VALUE : double
(0) ======================================================================
(0) Error: gsn_add_shapefile_polymarkers: geometry_type attribute must be
'point'
(0)       No shapefile information will be added.


I'll appreciate any suggestion on how I can plot this correctly.

Thank you in advance.

Lyndz
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://mailman.ucar.edu/pipermail/ncl-talk/attachments/20170703/fca21828/attachment.html 
-------------- next part --------------
A non-text attachment was scrubbed...
Name: test.ncl
Type: application/octet-stream
Size: 2800 bytes
Desc: not available
Url : http://mailman.ucar.edu/pipermail/ncl-talk/attachments/20170703/fca21828/attachment.obj 
-------------- next part --------------
A non-text attachment was scrubbed...
Name: test_data.zip
Type: application/zip
Size: 183880 bytes
Desc: not available
Url : http://mailman.ucar.edu/pipermail/ncl-talk/attachments/20170703/fca21828/attachment.zip 


More information about the ncl-talk mailing list