<?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 Difficulties displaying JS function based on feature field calculations in HTML web page in ArcGIS JavaScript Maps SDK Questions</title>
    <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/difficulties-displaying-js-function-based-on/m-p/1184655#M77730</link>
    <description>&lt;P&gt;Hello,&lt;/P&gt;&lt;P&gt;I am looking to display a statistic that I derived from a JS function, called "Weighted RSR". This statistic is calculated by the following equation:&lt;/P&gt;&lt;P&gt;(Sum(SquareYards * AdjustedRSR) )&amp;nbsp; &amp;nbsp;/&amp;nbsp; &amp;nbsp; (Sum(SquareYards))&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;The values "SquareYards" and "AdjustedRSR" are both attribute fields within a feature layer that I am embedding within an HTML web page.&amp;nbsp;&lt;/P&gt;&lt;P&gt;My workflow is the following:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Created Statistic queries (calculating sum) for the SquareYards and AdjustedRSR feature layer fields&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Stat_query.png" style="width: 400px;"&gt;&lt;img src="https://community.esri.com/t5/image/serverpage/image-id/43928i346D527A3DEB0CF4/image-size/medium?v=v2&amp;amp;px=400" role="button" title="Stat_query.png" alt="Stat_query.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;Created a function to calculate my desired Weighted RSR statistic that I am looking to display, and then I called that function within my JS file that contains my feature layer&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Weighted RSR function.png" style="width: 400px;"&gt;&lt;img src="https://community.esri.com/t5/image/serverpage/image-id/43929i4C191B9AC42E0E6A/image-size/medium?v=v2&amp;amp;px=400" role="button" title="Weighted RSR function.png" alt="Weighted RSR function.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;Note: "Current Road Surface Rating" is the terminology I am using to signify my Weighted RSR value within my web app&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Finally, referenced my JS file which contains my&amp;nbsp; statistic queries and Weighted RSR function&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="HTML page.png" style="width: 999px;"&gt;&lt;img src="https://community.esri.com/t5/image/serverpage/image-id/43930i006F27414C329E2D/image-size/large?v=v2&amp;amp;px=999" role="button" title="HTML page.png" alt="HTML page.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;When I test my project all I am able to see within my HTML page is my feature layer. I am unable to get the result of my WeightedRSR function to display on the HTML page.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Does my approach for creating a function which calculates the WeightedRSR function make sense? And does anyone have any insights as to why I am unable to have my function result display on my HTML page and/or tips on how I can get the function result to appear?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Any tips/recommendations/comments would be greatly appreciated.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Tue, 21 Jun 2022 14:04:24 GMT</pubDate>
    <dc:creator>MichaelGeorge1</dc:creator>
    <dc:date>2022-06-21T14:04:24Z</dc:date>
    <item>
      <title>Difficulties displaying JS function based on feature field calculations in HTML web page</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/difficulties-displaying-js-function-based-on/m-p/1184655#M77730</link>
      <description>&lt;P&gt;Hello,&lt;/P&gt;&lt;P&gt;I am looking to display a statistic that I derived from a JS function, called "Weighted RSR". This statistic is calculated by the following equation:&lt;/P&gt;&lt;P&gt;(Sum(SquareYards * AdjustedRSR) )&amp;nbsp; &amp;nbsp;/&amp;nbsp; &amp;nbsp; (Sum(SquareYards))&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;The values "SquareYards" and "AdjustedRSR" are both attribute fields within a feature layer that I am embedding within an HTML web page.&amp;nbsp;&lt;/P&gt;&lt;P&gt;My workflow is the following:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Created Statistic queries (calculating sum) for the SquareYards and AdjustedRSR feature layer fields&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Stat_query.png" style="width: 400px;"&gt;&lt;img src="https://community.esri.com/t5/image/serverpage/image-id/43928i346D527A3DEB0CF4/image-size/medium?v=v2&amp;amp;px=400" role="button" title="Stat_query.png" alt="Stat_query.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;Created a function to calculate my desired Weighted RSR statistic that I am looking to display, and then I called that function within my JS file that contains my feature layer&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Weighted RSR function.png" style="width: 400px;"&gt;&lt;img src="https://community.esri.com/t5/image/serverpage/image-id/43929i4C191B9AC42E0E6A/image-size/medium?v=v2&amp;amp;px=400" role="button" title="Weighted RSR function.png" alt="Weighted RSR function.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;Note: "Current Road Surface Rating" is the terminology I am using to signify my Weighted RSR value within my web app&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Finally, referenced my JS file which contains my&amp;nbsp; statistic queries and Weighted RSR function&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="HTML page.png" style="width: 999px;"&gt;&lt;img src="https://community.esri.com/t5/image/serverpage/image-id/43930i006F27414C329E2D/image-size/large?v=v2&amp;amp;px=999" role="button" title="HTML page.png" alt="HTML page.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;When I test my project all I am able to see within my HTML page is my feature layer. I am unable to get the result of my WeightedRSR function to display on the HTML page.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Does my approach for creating a function which calculates the WeightedRSR function make sense? And does anyone have any insights as to why I am unable to have my function result display on my HTML page and/or tips on how I can get the function result to appear?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Any tips/recommendations/comments would be greatly appreciated.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 21 Jun 2022 14:04:24 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/difficulties-displaying-js-function-based-on/m-p/1184655#M77730</guid>
      <dc:creator>MichaelGeorge1</dc:creator>
      <dc:date>2022-06-21T14:04:24Z</dc:date>
    </item>
  </channel>
</rss>

