Announcement

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

  • Export SHP from Stata

    Hello,
    I have been using the -shp2dta- command to bring in a GIS shapefile into Stata for editing. I was able to export the database, or attributes, portion back into the shapefile by exporting (and replacing the original) to a dBase (.DBF) file format. I was only wondering whether it is possible to do something similar / export the XY coordinate portion back into an .SHP file format by chance. Thank you for any help.

  • #2
    To the best of my knowledge Stata does not retain the spatial object type so it likely would not be possible without a fair amount of additional low-level programming work to write the data with the correct specification (which could be more difficult if you want cross platform support and have to deal with the endianness of the platform manually).

    Comment


    • #3
      Okay, thank you very much

      Comment


      • #4
        Straso Jovanovski ,

        see here:
        https://www.stata.com/meeting/canada...8_Radyakin.pdf

        and here:
        http://www.radyakin.org/stata/geotools/

        wbuchanan , yes it is low-level programming and yes it should create a valid file up to the specification, if not, let me know of an example please.

        Best, Sergiy

        Comment


        • #5
          Mr. Radyakin, thank you for your post. Does the -geotools- command have the option of working with actual shapefiles? I can only see the ability of inputting raw coordinate and attribute data with this. However, I need to be able to modify an actual preexisting shapefile and export changes in Stata. Thank you very much.

          Comment

          Working...
          X