<?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 Calculation help in ArcGIS Survey123 Questions</title>
    <link>https://community.esri.com/t5/arcgis-survey123-questions/calculation-help/m-p/1296080#M49709</link>
    <description>&lt;P&gt;I am trying to create a form to collect line-point intercept data within Survey 123. I have most of the meat done, I just need help with some calculations. I currently have the survey set up to collect multiple points of data with the begin repeat and end repeat functions. I need to be able to calculate PERCENT FOLIAR COVER by taking the total number of entries for my "TOP LAYER" field across the entire repeated survey then divide those over the total number of points sampled and multiply by 100 to get my average percent.&lt;/P&gt;&lt;P&gt;I need to do the same thing to determine PERCENT BARE GROUND, which is calculated by taking the total number of soil entries in the SOIL SURFACE question AND have no answers in the Top LAYER field, dividing the total number of points, and multiplying by 100. The same thing for PERCENT BASAL COVER, but it can include any entries with entries in the TOP LAYER or subsequent fields.&lt;/P&gt;&lt;P&gt;My XLSForm and an example of the data sheet I am trying to replicate are attached so you can see where I am at.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks in advance for any help.&lt;/P&gt;</description>
    <pubDate>Mon, 05 Jun 2023 23:04:30 GMT</pubDate>
    <dc:creator>MatthewMorehead</dc:creator>
    <dc:date>2023-06-05T23:04:30Z</dc:date>
    <item>
      <title>Calculation help</title>
      <link>https://community.esri.com/t5/arcgis-survey123-questions/calculation-help/m-p/1296080#M49709</link>
      <description>&lt;P&gt;I am trying to create a form to collect line-point intercept data within Survey 123. I have most of the meat done, I just need help with some calculations. I currently have the survey set up to collect multiple points of data with the begin repeat and end repeat functions. I need to be able to calculate PERCENT FOLIAR COVER by taking the total number of entries for my "TOP LAYER" field across the entire repeated survey then divide those over the total number of points sampled and multiply by 100 to get my average percent.&lt;/P&gt;&lt;P&gt;I need to do the same thing to determine PERCENT BARE GROUND, which is calculated by taking the total number of soil entries in the SOIL SURFACE question AND have no answers in the Top LAYER field, dividing the total number of points, and multiplying by 100. The same thing for PERCENT BASAL COVER, but it can include any entries with entries in the TOP LAYER or subsequent fields.&lt;/P&gt;&lt;P&gt;My XLSForm and an example of the data sheet I am trying to replicate are attached so you can see where I am at.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks in advance for any help.&lt;/P&gt;</description>
      <pubDate>Mon, 05 Jun 2023 23:04:30 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-survey123-questions/calculation-help/m-p/1296080#M49709</guid>
      <dc:creator>MatthewMorehead</dc:creator>
      <dc:date>2023-06-05T23:04:30Z</dc:date>
    </item>
    <item>
      <title>Re: Calculation help</title>
      <link>https://community.esri.com/t5/arcgis-survey123-questions/calculation-help/m-p/1296143#M49712</link>
      <description>&lt;P&gt;I think this post has almost all you need &lt;A href="https://community.esri.com/t5/arcgis-survey123-blog/survey123-tricks-of-the-trade-repeats/ba-p/898041" target="_blank"&gt;https://community.esri.com/t5/arcgis-survey123-blog/survey123-tricks-of-the-trade-repeats/ba-p/898041&lt;/A&gt; - you might have to add some logic with ifs around the calculations. Sometimes it's helpful to add some calculate fields to check for the intermediate results.&lt;/P&gt;&lt;P&gt;The SOIL_SURFACE question is the only required question in the repeat, right? This one you could use for counting the valid repeats so the first calculation could be&lt;/P&gt;&lt;P&gt;count(${TOP_LAYER}) div count(${SOIL_SURFACE}) *100&lt;/P&gt;&lt;P&gt;Maybe you need to add round() to get readable numbers.&lt;/P&gt;&lt;P&gt;For the percentage bare ground I would add a hidden field inside the repeat that populates based on if(${TOP_LAYER},'',${SOIL_SURFACE})&amp;nbsp; and then use count again on that new field (you could also do 0&amp;nbsp; if TOP_LAYER&amp;nbsp; and 1 if not and then use the sum function).&lt;/P&gt;&lt;P&gt;For the last one I am not 100% what you need to do but I think you will get there now.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 06 Jun 2023 08:00:20 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-survey123-questions/calculation-help/m-p/1296143#M49712</guid>
      <dc:creator>Nicole_Ueberschär</dc:creator>
      <dc:date>2023-06-06T08:00:20Z</dc:date>
    </item>
    <item>
      <title>Re: Calculation help</title>
      <link>https://community.esri.com/t5/arcgis-survey123-questions/calculation-help/m-p/1296216#M49725</link>
      <description>&lt;P&gt;I have a advanced LPI form that we have been perfecting for 5 years now. Reach out to me if intrested.&amp;nbsp;&lt;/P&gt;&lt;P&gt;We do some summary calcs in the form for the users as you describe.&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="DougBrowning_0-1686058912261.png" style="width: 400px;"&gt;&lt;img src="https://community.esri.com/t5/image/serverpage/image-id/72436iED19023434F2093A/image-size/medium?v=v2&amp;amp;px=400" role="button" title="DougBrowning_0-1686058912261.png" alt="DougBrowning_0-1686058912261.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;If you have a repeat like us you have to double count.&amp;nbsp; So inside the repeat and then again outside the repeat.&amp;nbsp; Pretty hard to explain here so each out to me.&lt;/P&gt;</description>
      <pubDate>Tue, 06 Jun 2023 13:42:44 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-survey123-questions/calculation-help/m-p/1296216#M49725</guid>
      <dc:creator>DougBrowning</dc:creator>
      <dc:date>2023-06-06T13:42:44Z</dc:date>
    </item>
    <item>
      <title>Re: Calculation help</title>
      <link>https://community.esri.com/t5/arcgis-survey123-questions/calculation-help/m-p/1296453#M49739</link>
      <description>&lt;P&gt;Here is an example&lt;/P&gt;&lt;P&gt;Inside the repeat&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="DougBrowning_0-1686081033044.png" style="width: 769px;"&gt;&lt;img src="https://community.esri.com/t5/image/serverpage/image-id/72500i0042D6A76A890B04/image-dimensions/769x123?v=v2" width="769" height="123" role="button" title="DougBrowning_0-1686081033044.png" alt="DougBrowning_0-1686081033044.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Then outside&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="DougBrowning_1-1686081060274.png" style="width: 758px;"&gt;&lt;img src="https://community.esri.com/t5/image/serverpage/image-id/72501iC9F420FFA2438C47/image-dimensions/758x382?v=v2" width="758" height="382" role="button" title="DougBrowning_1-1686081060274.png" alt="DougBrowning_1-1686081060274.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;I can get you the form ready to go just lmk.&lt;/P&gt;</description>
      <pubDate>Tue, 06 Jun 2023 19:51:30 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-survey123-questions/calculation-help/m-p/1296453#M49739</guid>
      <dc:creator>DougBrowning</dc:creator>
      <dc:date>2023-06-06T19:51:30Z</dc:date>
    </item>
  </channel>
</rss>

