# Measure Length Inside Polygon Edge to Edge

352
5
07-19-2023 01:41 PM
Labels (1)
New Contributor III

I am trying to figure out how to measure the distance within a polygon from edge to edge, or the longest side from north to south (including multiple segments that make that side up) of the polygon. I need to do this in Arcade. If anyone has approached this and point me in the right direction, I would appreciate it.

Thanks

Tags (6)
1 Solution

Accepted Solutions
MVP Frequent Contributor

I had similar question and @JohannesLindner helped me out with this post here.

Might get you what you need or at least point you in the right direction.

R_

5 Replies
MVP Frequent Contributor

I had similar question and @JohannesLindner helped me out with this post here.

Might get you what you need or at least point you in the right direction.

R_

New Contributor III

Thanks.

It did. It seems to be, in miles, about .10 off always. I will ask in the other post about that.

Thanks again

MVP Frequent Contributor

Did you put the units you want as the last option in the Distance (supposed to return map units, but I found that to not be the case.  I had to specify feet)?

Also, is you data in a projected coordinate system?  If not, may have something to do with it being 0.1 off.

All my date is projected in state plane, so not sure if it would vary if GCS, but often when numbers are a bit odd, that is the case.

R_

MVP Frequent Contributor

Also, not sure what 'profile' you are using, but Distance says

"Feature geometries in the visualization and labeling profiles are generalized according to the view's scale resolution to improve drawing performance. Therefore, using a feature's geometry (i.e. \$feature) as input to any geometry function in these contexts will return different results at each scale level. Other profiles, such as popup, provide the full resolution geometry."

but doesn't say anything about calculation profile.....

I used it in an attribute rule with State Plane data, and it appears to be spot on.

R_

New Contributor III

The distanceGeodetic did the trick. I was able to get the same as the widget.

I just need to update it to add all the segments that make up the longest side.

Thanks!!