Announcement

Collapse
No announcement yet.
X
  • Filter
  • Time
  • Show
Clear All
new posts

  • Exporting shapefiles with nonconsecutive, multipart polygons using Geotools

    I am using the -geotools- command to export polygon features to an ESRI shapefile. The input geography file was derived from the output of -shp2dta-. I wonder if there is a way to deal with the export of shapefiles using -geotools- in the case of multipart polygon features. I am encountering problems with this. As per the user manual / notes on the tool, it does not support the export of such features - polygons with holes, or nonconsecutive, multipart polygons. As a result, polygon features made up of multiple parts come out as fully distorted when mapping the output shapefile. Would anyone know of a workaround to this? I am using Stata16 MP2. Thank you very much for any help.

  • #2
    Straso Jovanovski refers to the -geotools- package http://www.radyakin.org/stata/geotools/
    As the author of this package I can confirm that it was written without taking into account the type of irregular polygons mentioned by Straso.
    I am also not aware of any workarounds for fulfilling that task.
    Best, Sergiy Radyakin

    Comment


    • #3
      Straso Jovanovski has further contacted me privately with a question regarding distortion of the order of vertices in the produced shapefile.

      As per the ESRI specification of the shapefile format, (page 8):
      Vertices for a single, ringed polygon are, therefore, always in clockwise order.
      -geotools- was written with understanding that human operators outlining the features on a base map will not always follow the clockwise order of vertices.

      Hence -geotools- will reverse the order of the vertices if it finds them in the counterclockwise order. Determining the direction may not be working correctly in the case of degenerate, disjoint, or otherwise unexpectedly-shaped polygons, that Straso has asked in the first message above.

      Comment

      Working...
      X