Mean Center/Median Center tool providing points mathematically centered but physically appearing in the wrong location

4114
7
02-27-2015 01:22 PM
AidaGuhlin
New Contributor II

To create population weights, I'm using the Mean and Median Center tool to find the center of our populations in census tracts. However, I've noticed that some of the points that are popping up are physically appearing in the census tract next to the census tract they should be in, resulting in two points in one tract when there should be just one. However, the attribute table does verify that they are belonging to a different census tract, just not physically displaying them in the different census tract. Has anyone run into this issue? Does anyone know how to fix it?

0 Kudos
7 Replies
MelitaKennedy
Esri Notable Contributor

Does the tract where the point falls outside have an non-rectangular shape? This may be the same problem as calculating the centroid--it's not guaranteed to fall within the polygon.

AidaGuhlin
New Contributor II

Both tracts actually are not rectangular in what appears to be all of the cases. By calculating the centroid, could you elaborate?

0 Kudos
DarrenWiens2
MVP Honored Contributor

If you have a polygon shaped like the letter 'C', the centroid will be outside the lines of the polygon 'C', right in the middle (similar for many other complex shapes).

AidaGuhlin
New Contributor II

Oh right, I remember this. So do you think this is the case?

0 Kudos
AidaGuhlin
New Contributor II

Actually, looking at all of the places where this occurred...this might be the case. Any suggestions on how to rectify it?

0 Kudos
MelitaKennedy
Esri Notable Contributor

If you really want the centroid but want the point to fall within the feature (aka not the true centroid any more), look at the Calculate Field tool. When I trace the centroid concept back to the arcpy geometry, it says that it returns the centroid if the point will fall in or on the edge of a feature. Otherwise, it returns a label point. That is, the returned point is constrained to fall within/on the edge of the feature. I thought there was a separate tool...

AidaGuhlin
New Contributor II

Thanks Melita Kennedy​! I'll be sure to try that and see what I get and provide an update!

0 Kudos