Point Geometry to feature class?

786
2
08-01-2017 10:52 AM
AndrewMartin8
New Contributor III

I am trying to take a point in a xy coordinate and putting a gis coordinate with it. Now I am taking the pointgeometry  and creating a feature class or a shape file. What is the function for this? and how can I make it have unique file names after every loop?

for columns in range(0,9111):
point=arcpy.Point(dem_order.xmin + columns, dem_order.YMin)
pointval= arcpy.GetCellValue_management("dem_order","point", "2")
if (pointval==1 || pointval==2 || pointval==3):
pointgeom = arcpy.pointgeometry(point,"W:\ArcMap\Coordinate_Systems\NAD 1983 StatePlane Texas S Central FIPS 4204 (US Feet) SURFACE.prj")‍‍‍‍‍

Let me know if my thought process of this code is correct. I am taking a stream order  raster and only scanning the bottom row and if it has any of those stream values. I am going to put a shapefile at that point, so I can create a watershed at that point.

0 Kudos
2 Replies
RebeccaStrauch__GISP
MVP Emeritus

fyi - you could have editing the other post instead of createing a new.  I know it does take a while to learn allt he how to's of Geonet.  You can probably just delete the other post Point geometry to feature class? 

You code above is still not formatted quite right, so you would immediately get a syntax error.  I see you did add the : which is good, but the lines below it that should be in the block need to be indented.  Tab or spaces...just should be consistent.  To break out of the code block you "undent".  If you get a good IDE (development environment that handles python .. I use Wingware - Wing Python IDE  but there are many) it will help with the python syntax.

It looks like you are wanting information from the DEM raster cells?  it that correct?  You may just want to look at

Raster to Point—Help | ArcGIS Desktop 

Please include when version of the software you are.

DanPatterson_Retired
MVP Emeritus

For those trying to follow along....

In one of your other threads... Copy Features was recommended Posting in one location makes it easier for people to keep track of a question and its incarnations.