Now—at least in case of multipatch inputs—the result is planar. I’d like to see results like points created by arcpy.PointGeometry.centroid and/or arcpy.PointGeometry.trueCentroid.
The Feature to Point can produce Z aware FeatureClasses. It is an environment setting "Output has Z values".
Thanks to Duncan Hornby for providing that response. I was going to respond with this: Feature To Point—Data Management toolbox | ArcGIS Desktop and in addition to what Duncan wrote, there is also a Default Output Z Value (Environment setting)—Geoprocessing | ArcGIS Desktop
This idea will be marked as Already Offered.
I wasn’t precise enough… Technically it can produce 3D output and it does produce 3D output. However the Z values of the vertices is fulfilled with zeros (at least in case of multipatch and multipoint inputs). Which is not exactly 3D any more if the input features are several thousand feet above the reference surface. But yes, technically it is 3D. So it is already offered, but it’s never implemented and never going to be implemented. (Reading about something in a manual is helpful, but not enough. Someone have to try it in the reality)
Where would the Z value come from? Is there an attribute with a Z value, or would you expect it to be derived from a surface?
Would either of these tools accomplish what you're looking to do?
Feature To 3D By Attribute—Help | ArcGIS Desktop
Interpolate Shape—Help | ArcGIS Desktop
Let’s imagine a triangle in a Cartesian (projected-) coordinate system, with the following coordinates: A(1, 1, 2), B(3, 1, 2) and C(1.5, 3, 2) where the fist number of the coordinate is measured in metes, along the X axis, the second number is measured along the Y axis, and the third one measured along the Z axis. The order of the coordinates is counter clockwise. Actually, the Z value is constantly 2 for all the points. How can we calculate the centroid of this polygon (triangle)? CentroidX= (AX+BX+CX)/3; CentroidY=(AY+BY+CY)/3; CentroidZ=(AZ+BZ+CZ)/3. The results are the following: Centroid(1.833333, 1.666666, 2). This coordinate point is inside, on the plane of the triangle. If I use the Feature to Point against this triangle the result is Centroid(1.833333, 1.666666, NaN), where the “NaN” means “Not a Number” (it represented as 0 on the user interface). The result in the XY plane is correct, but the Z coordinate is missing (or zeroed). In this case the output feature class is technically z aware, but there is no Z information inside. In arcpy the Polygon.centroid() function calculates the correct Centroid(1.833333, 1.666666, 2) value. It would be beneficial if the results would be the same. I think the algorithm of the “Feature to Point” was written before the introduction of the idea of Z aware feature classes.
Thank you for the excellent detail, Ákos Halmai I've updated the status to Reviewed for voting.
Thanks again for taking the time to provide a very clear understanding of the issue and request!
Oh, and remember to up vote your idea:)
I posted it as an idea, but from different point of view it could be a bug.
2017-09-19 15:50 GMT+02:00 Kory Kramer <firstname.lastname@example.org>:
GeoNet <https://community.esri.com/?et=notification.mention>You have been mentioned by Kory Kramer<https://community.esri.com/people/KKramer-esristaff?et=notification.mention> *inMake the “Feature To Point” able geoprocess to create 3D point featureclass as output feature class. in GeoNet* - View Kory Kramer's referenceto you<https://community.esri.com/ideas/13957-make-able-the-feature-to-point-geoprocess-to-create-3d-point-feature-class-as-output-feature-class?commentID=51227&et=notification.mention#comment-51227>
You have been mentioned
by Kory Kramer
Make the “Feature To Point” able geoprocess to create 3D point feature
class as output feature class. in GeoNet* - View Kory Kramer's reference
I've submitted the following enhancement request for the tool:
ENH-000108562: Output from the Feature to Point tool should correctly calculate an interpolated Z value for the centroid.
Thanks! It will be useful.
Retrieving data ...