<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: Arcade-Difference between Buffer Distance and Actual Route Distance in ArcGIS Online Questions</title>
    <link>https://community.esri.com/t5/arcgis-online-questions/arcade-difference-between-buffer-distance-and/m-p/166229#M8121</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi&amp;nbsp;&lt;A href="https://community.esri.com/migrated-users/277752"&gt;MR Reddy&lt;/A&gt;&amp;nbsp;,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;There are a couple of things to keep in mind:&lt;/P&gt;&lt;UL&gt;&lt;LI&gt;When working with a geometry in Arcade derived from $feature the precision depends on the view scale. When you are zoomed out your geometry will be generalized (this will be more the case with lines and polygons).&lt;/LI&gt;&lt;LI&gt;Using the Distance or&amp;nbsp;DistanceGeodetic functions in arcade will return the distance in a straight line which will normally be less than when you determine the distance using routing.&lt;/LI&gt;&lt;LI&gt;Currently you cannot invoke a service (for instance a routing service) te determine the distance based on routing.&amp;nbsp;However, this is something that might be introduced later on.&lt;/LI&gt;&lt;LI&gt;When you look for addresses within a distance of 200 feet, I assume the distance resulted from routing will not be very larger than the one returned from a straight line&amp;nbsp;in many situations.&lt;/LI&gt;&lt;/UL&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Sat, 23 May 2020 20:24:19 GMT</pubDate>
    <dc:creator>XanderBakker</dc:creator>
    <dc:date>2020-05-23T20:24:19Z</dc:date>
    <item>
      <title>Arcade-Difference between Buffer Distance and Actual Route Distance</title>
      <link>https://community.esri.com/t5/arcgis-online-questions/arcade-difference-between-buffer-distance-and/m-p/166228#M8120</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I used the similar code in arcade to find the nearest address point(&lt;A href="https://community.esri.com/thread/241598" target="_blank"&gt;Using Arcade to Find the Nearest Address Point&lt;/A&gt; )&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;My question is does the distance calculated by buffer and route service are same or almost same&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;or is it possible to find nearest distance&amp;nbsp; from $feature to address&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE class="lia-code-sample line-numbers language-none"&gt;&lt;CODE&gt;&lt;SPAN class="keyword token"&gt;var&lt;/SPAN&gt; searchDist &lt;SPAN class="operator token"&gt;=&lt;/SPAN&gt; &lt;SPAN class="number token"&gt;200&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;;&lt;/SPAN&gt;
&lt;SPAN class="keyword token"&gt;var&lt;/SPAN&gt; addresses &lt;SPAN class="operator token"&gt;=&lt;/SPAN&gt; &lt;SPAN class="token function"&gt;Intersects&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;(&lt;/SPAN&gt;&lt;SPAN class="token function"&gt;FeatureSetById&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;(&lt;/SPAN&gt;$map&lt;SPAN class="punctuation token"&gt;,&lt;/SPAN&gt; &lt;SPAN class="string token"&gt;"Primary_Address_3482"&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;)&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;,&lt;/SPAN&gt; &lt;SPAN class="token function"&gt;Buffer&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;(&lt;/SPAN&gt; $feature&lt;SPAN class="punctuation token"&gt;,&lt;/SPAN&gt; searchDist&lt;SPAN class="punctuation token"&gt;,&lt;/SPAN&gt; &lt;SPAN class="string token"&gt;"feet"&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;)&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;)&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;;&lt;/SPAN&gt;
&lt;SPAN class="keyword token"&gt;var&lt;/SPAN&gt; cnt &lt;SPAN class="operator token"&gt;=&lt;/SPAN&gt; &lt;SPAN class="token function"&gt;Count&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;(&lt;/SPAN&gt;addresses&lt;SPAN class="punctuation token"&gt;)&lt;/SPAN&gt;
&lt;SPAN class="token function"&gt;Console&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;(&lt;/SPAN&gt;&lt;SPAN class="string token"&gt;"Total Number of addresses within buffer: "&lt;/SPAN&gt; &lt;SPAN class="operator token"&gt;+&lt;/SPAN&gt; cnt&lt;SPAN class="punctuation token"&gt;)&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;;&lt;/SPAN&gt;
&lt;SPAN class="keyword token"&gt;var&lt;/SPAN&gt; nearestaddress&lt;SPAN class="punctuation token"&gt;;&lt;/SPAN&gt;
&lt;SPAN class="keyword token"&gt;var&lt;/SPAN&gt; min_dist &lt;SPAN class="operator token"&gt;=&lt;/SPAN&gt; &lt;SPAN class="number token"&gt;250&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;;&lt;/SPAN&gt;
&lt;SPAN class="keyword token"&gt;for&lt;/SPAN&gt; &lt;SPAN class="punctuation token"&gt;(&lt;/SPAN&gt;&lt;SPAN class="keyword token"&gt;var&lt;/SPAN&gt; f &lt;SPAN class="keyword token"&gt;in&lt;/SPAN&gt; addresses&lt;SPAN class="punctuation token"&gt;)&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;{&lt;/SPAN&gt;
 &lt;SPAN class="keyword token"&gt;var&lt;/SPAN&gt; addressDist &lt;SPAN class="operator token"&gt;=&lt;/SPAN&gt; &lt;SPAN class="token function"&gt;Round&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;(&lt;/SPAN&gt;&lt;SPAN class="token function"&gt;Distance&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;(&lt;/SPAN&gt;f&lt;SPAN class="punctuation token"&gt;,&lt;/SPAN&gt; $feature&lt;SPAN class="punctuation token"&gt;,&lt;/SPAN&gt; &lt;SPAN class="string token"&gt;"feet"&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;)&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;,&lt;/SPAN&gt;&lt;SPAN class="number token"&gt;2&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;)&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;;&lt;/SPAN&gt;
 &lt;SPAN class="keyword token"&gt;if&lt;/SPAN&gt; &lt;SPAN class="punctuation token"&gt;(&lt;/SPAN&gt;addressDist &lt;SPAN class="operator token"&gt;&amp;lt;&lt;/SPAN&gt; min_dist&lt;SPAN class="punctuation token"&gt;)&lt;/SPAN&gt; &lt;SPAN class="punctuation token"&gt;{&lt;/SPAN&gt;
     nearestaddress &lt;SPAN class="operator token"&gt;=&lt;/SPAN&gt; f&lt;SPAN class="punctuation token"&gt;.&lt;/SPAN&gt;FULL_ADDR&lt;SPAN class="punctuation token"&gt;;&lt;/SPAN&gt;
     min_dist &lt;SPAN class="operator token"&gt;=&lt;/SPAN&gt; addressDist&lt;SPAN class="punctuation token"&gt;;&lt;/SPAN&gt;
 &lt;SPAN class="punctuation token"&gt;}&lt;/SPAN&gt;
 &lt;SPAN class="token function"&gt;Console&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;(&lt;/SPAN&gt;f&lt;SPAN class="punctuation token"&gt;.&lt;/SPAN&gt;FULL_ADDR &lt;SPAN class="operator token"&gt;+&lt;/SPAN&gt; &lt;SPAN class="string token"&gt;": "&lt;/SPAN&gt; &lt;SPAN class="operator token"&gt;+&lt;/SPAN&gt; &lt;SPAN class="string token"&gt;" "&lt;/SPAN&gt; &lt;SPAN class="operator token"&gt;+&lt;/SPAN&gt; addressDist&lt;SPAN class="punctuation token"&gt;)&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;;&lt;/SPAN&gt;
&lt;SPAN class="punctuation token"&gt;}&lt;/SPAN&gt;

&lt;SPAN class="keyword token"&gt;return&lt;/SPAN&gt; nearestaddress&lt;SPAN class="punctuation token"&gt;;&lt;/SPAN&gt;‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍&lt;SPAN class="line-numbers-rows"&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;A href="https://community.esri.com/migrated-users/3100" target="_blank"&gt;Xander Bakker&lt;/A&gt;‌&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 11 Dec 2021 08:40:02 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-online-questions/arcade-difference-between-buffer-distance-and/m-p/166228#M8120</guid>
      <dc:creator>Pa_Lotus</dc:creator>
      <dc:date>2021-12-11T08:40:02Z</dc:date>
    </item>
    <item>
      <title>Re: Arcade-Difference between Buffer Distance and Actual Route Distance</title>
      <link>https://community.esri.com/t5/arcgis-online-questions/arcade-difference-between-buffer-distance-and/m-p/166229#M8121</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi&amp;nbsp;&lt;A href="https://community.esri.com/migrated-users/277752"&gt;MR Reddy&lt;/A&gt;&amp;nbsp;,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;There are a couple of things to keep in mind:&lt;/P&gt;&lt;UL&gt;&lt;LI&gt;When working with a geometry in Arcade derived from $feature the precision depends on the view scale. When you are zoomed out your geometry will be generalized (this will be more the case with lines and polygons).&lt;/LI&gt;&lt;LI&gt;Using the Distance or&amp;nbsp;DistanceGeodetic functions in arcade will return the distance in a straight line which will normally be less than when you determine the distance using routing.&lt;/LI&gt;&lt;LI&gt;Currently you cannot invoke a service (for instance a routing service) te determine the distance based on routing.&amp;nbsp;However, this is something that might be introduced later on.&lt;/LI&gt;&lt;LI&gt;When you look for addresses within a distance of 200 feet, I assume the distance resulted from routing will not be very larger than the one returned from a straight line&amp;nbsp;in many situations.&lt;/LI&gt;&lt;/UL&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 23 May 2020 20:24:19 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-online-questions/arcade-difference-between-buffer-distance-and/m-p/166229#M8121</guid>
      <dc:creator>XanderBakker</dc:creator>
      <dc:date>2020-05-23T20:24:19Z</dc:date>
    </item>
  </channel>
</rss>

