Select to view content in your preferred language

Speeding up finding the minimum point

3157
18
08-31-2016 10:09 AM
JohnWall
Regular Contributor

I am trying to get the point of the lowest elevation within a series of polygons (see attached). However, it seems to take nearly a minute for one point to be created. I've tried to speed this up by extracting the elevation just within the buffers for analysis and to reduce data size. I've also set the environment to the polygon that is being iterated on. Any suggestions?

0 Kudos
18 Replies
DanPatterson_Retired
MVP Emeritus

Can you clarify why you are iterating the selection rather than doing it all at once?  If each polygon has a unique ID (which it will), then any number of options but Zonal Statistics or Zonal Statistics as Table would be the first go to.  Or is there something in the geometry or the subsequent workflow that precludes this?

0 Kudos
JohnWall
Regular Contributor

Hi Dan,

I've tried running it all at once, but the select each feature seems to work the best because it finds the lowest elevation within each buffer rather than merging the values into a single raster layer. Does this answer your question?

0 Kudos
DanPatterson_Retired
MVP Emeritus

I guess I wasn't sure if you were going to use the zonal geometry centroid to denote the 'central' points for each zone using the minimum value for the zone, or if you wanted all the point locations within each zone where the minimum was located.

0 Kudos
JohnWall
Regular Contributor

Ah, no, I am not trying to locate the centroid, but the location of the minimum elevation within each polygon then convert that raster location to a point storing the elevation of that point.

0 Kudos
DanPatterson_Retired
MVP Emeritus

Ok... but you could have many points which have the minimum... which is ok, I just wasn't sure if you just needed one or all.

0 Kudos
JohnWall
Regular Contributor

I just need one and it seems like, when I run this model on a smaller dataset, that there is only one location identified.

0 Kudos
DanPatterson_Retired
MVP Emeritus

How Zonal Statistics works—Help | ArcGIS for Desktop Zonal Minimum example

No, it assigns the whole zone the minimum value.  Maybe your polygon has all unique values.

Check for a polygon that has a contour line crossing it... you would definitely get a series of points along the contour.

In any event, even if it returned a bunch of points, taking the median or average location would work well for most convex polygons.

0 Kudos
JohnWall
Regular Contributor

Right, it does assign the whole zone the minimum which I then use to find the elevation from the DEM, within the zone, that equals the minimum.

0 Kudos
DanPatterson_Retired
MVP Emeritus

yes... the zone will find the minimum elevation... let's say you have a square zone and a flat DEM... the square zone will return the elevation of the flat surface, which is the minimum.  This value will be assigned to the zone (which is a raster by the way), that zone will undoubtedly consist of many cells, when the zone is converted to points, you will have many points with the same value.  

I would draw a picture, but looking picture of a small sample of your data would even be better given that the chances of every cell within the zone having unique elevations are pretty slim unless you are recording elevation to 4,5,6+ decimal points (which would be just plain wrong)

0 Kudos