<?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: Frontend: Grouping values in a dynamic list into ordered unique groups in App Development</title>
    <link>https://community.qlik.com/t5/App-Development/Frontend-Grouping-values-in-a-dynamic-list-into-ordered-unique/m-p/2487644#M101545</link>
    <description>&lt;P&gt;Calculate field, DDD &amp;amp; EEE are not 'nearby' AAA. nearby is precalculated.&lt;/P&gt;</description>
    <pubDate>Thu, 17 Oct 2024 12:10:13 GMT</pubDate>
    <dc:creator>Tomm</dc:creator>
    <dc:date>2024-10-17T12:10:13Z</dc:date>
    <item>
      <title>Frontend: Grouping values in a dynamic list into ordered unique groups</title>
      <link>https://community.qlik.com/t5/App-Development/Frontend-Grouping-values-in-a-dynamic-list-into-ordered-unique/m-p/2487531#M101535</link>
      <description>&lt;P&gt;Hello all,&lt;/P&gt;
&lt;P&gt;Looking for a bit of advice on how to approach a problem.&lt;/P&gt;
&lt;P&gt;I am seeking to identify groups of polygons from a dynamic population of polygons. My two main criteria are;&lt;/P&gt;
&lt;P&gt;1. The grouped polygons need to be relatively small in terms of sqkm. This one is solved by finding the polygons that are, in terms of sqkm, &amp;lt;5% of the maximum polygon in the set.&lt;/P&gt;
&lt;P&gt;2. The grouped should be for polygons that fall within x km of each other. Current approach is to join each polygon to all other polygons and measure the distance between centroids. I then retaining those that fall under X - in addition i'm using only({&amp;lt; Target_Polygon = P(Polygon) &amp;gt;} Target_Polygon) to limit the 'nearby polygons' by filters affecting the dynamic list of polygons.&lt;/P&gt;
&lt;P&gt;Formula:&amp;nbsp;&lt;/P&gt;
&lt;DIV&gt;
&lt;P&gt;=AGGR(NODISTINCT&lt;/P&gt;
&lt;P&gt;ONLY({&amp;lt;TARGET_POLYGON=P(POLYGON)&amp;gt;}&amp;nbsp;&lt;/P&gt;
&lt;P&gt;IF(AGGR(TARGET_POLYGON_SQKM/MAX(TOTAL POLYGON_SQKM), TARGET_POLYGON)&amp;lt;0.005 ,TARGET_POLYGON)&lt;/P&gt;
&lt;P&gt;)&lt;/P&gt;
&lt;P&gt;,TARGET_POLYGON&lt;/P&gt;
&lt;P&gt;)&lt;/P&gt;
&lt;/DIV&gt;
&lt;DIV&gt;&amp;nbsp;&lt;/DIV&gt;
&lt;P&gt;Problem: Using the Qlik Sense front end I want to group clusters of polygons (dynamic list based on user selections) starting the with the biggest cluster until I reach X groups. Where a location is already grouped it should not be included in subsequent groups.&lt;/P&gt;
&lt;P&gt;Example below; Left is current format - Right is desired output.&lt;/P&gt;
&lt;TABLE width="951"&gt;
&lt;TBODY&gt;
&lt;TR&gt;
&lt;TD width="185.069px" height="25px"&gt;DYNAMIC_LOCATIONS&lt;/TD&gt;
&lt;TD width="250.885px" height="25px"&gt;PRECALC_NEARBY_LOCATION&lt;/TD&gt;
&lt;TD width="232.205px" height="25px"&gt;COUNT_NEARBY_LOCATION&lt;/TD&gt;
&lt;TD width="40px" height="25px"&gt;&amp;nbsp;&lt;/TD&gt;
&lt;TD width="40px" height="25px"&gt;&amp;nbsp;&lt;/TD&gt;
&lt;TD width="185.069px" height="25px"&gt;DYNAMIC_LOCATIONS&lt;/TD&gt;
&lt;TD width="169.965px" height="25px"&gt;LOCATION_GROUPS&lt;/TD&gt;
&lt;/TR&gt;
&lt;TR&gt;
&lt;TD width="185.069px" height="25px"&gt;AAA&lt;/TD&gt;
&lt;TD width="250.885px" height="25px"&gt;AAA&lt;/TD&gt;
&lt;TD width="232.205px" height="25px"&gt;3&lt;/TD&gt;
&lt;TD width="40px" height="25px"&gt;&amp;nbsp;&lt;/TD&gt;
&lt;TD width="40px" height="25px"&gt;&amp;nbsp;&lt;/TD&gt;
&lt;TD width="185.069px" height="25px"&gt;AAA&lt;/TD&gt;
&lt;TD width="169.965px" height="25px"&gt;GROUP_1&lt;/TD&gt;
&lt;/TR&gt;
&lt;TR&gt;
&lt;TD width="185.069px" height="25px"&gt;AAA&lt;/TD&gt;
&lt;TD width="250.885px" height="25px"&gt;BBB&lt;/TD&gt;
&lt;TD width="232.205px" height="25px"&gt;3&lt;/TD&gt;
&lt;TD width="40px" height="25px"&gt;&amp;nbsp;&lt;/TD&gt;
&lt;TD width="40px" height="25px"&gt;&amp;nbsp;&lt;/TD&gt;
&lt;TD width="185.069px" height="25px"&gt;BBB&lt;/TD&gt;
&lt;TD width="169.965px" height="25px"&gt;GROUP_1&lt;/TD&gt;
&lt;/TR&gt;
&lt;TR&gt;
&lt;TD width="185.069px" height="25px"&gt;AAA&lt;/TD&gt;
&lt;TD width="250.885px" height="25px"&gt;CCC&lt;/TD&gt;
&lt;TD width="232.205px" height="25px"&gt;3&lt;/TD&gt;
&lt;TD width="40px" height="25px"&gt;&amp;nbsp;&lt;/TD&gt;
&lt;TD width="40px" height="25px"&gt;&amp;nbsp;&lt;/TD&gt;
&lt;TD width="185.069px" height="25px"&gt;CCC&lt;/TD&gt;
&lt;TD width="169.965px" height="25px"&gt;GROUP_1&lt;/TD&gt;
&lt;/TR&gt;
&lt;TR&gt;
&lt;TD width="185.069px" height="25px"&gt;BBB&lt;/TD&gt;
&lt;TD width="250.885px" height="25px"&gt;AAA&lt;/TD&gt;
&lt;TD width="232.205px" height="25px"&gt;2&lt;/TD&gt;
&lt;TD width="40px" height="25px"&gt;&amp;nbsp;&lt;/TD&gt;
&lt;TD width="40px" height="25px"&gt;&amp;nbsp;&lt;/TD&gt;
&lt;TD width="185.069px" height="25px"&gt;DDD&lt;/TD&gt;
&lt;TD width="169.965px" height="25px"&gt;GROUP_2&lt;/TD&gt;
&lt;/TR&gt;
&lt;TR&gt;
&lt;TD width="185.069px" height="25px"&gt;BBB&lt;/TD&gt;
&lt;TD width="250.885px" height="25px"&gt;BBB&lt;/TD&gt;
&lt;TD width="232.205px" height="25px"&gt;2&lt;/TD&gt;
&lt;TD width="40px" height="25px"&gt;&amp;nbsp;&lt;/TD&gt;
&lt;TD width="40px" height="25px"&gt;&amp;nbsp;&lt;/TD&gt;
&lt;TD width="185.069px" height="25px"&gt;EEE&lt;/TD&gt;
&lt;TD width="169.965px" height="25px"&gt;GROUP_2&lt;/TD&gt;
&lt;/TR&gt;
&lt;TR&gt;
&lt;TD width="185.069px" height="25px"&gt;CCC&lt;/TD&gt;
&lt;TD width="250.885px" height="25px"&gt;AAA&lt;/TD&gt;
&lt;TD width="232.205px" height="25px"&gt;2&lt;/TD&gt;
&lt;TD width="40px" height="25px"&gt;&amp;nbsp;&lt;/TD&gt;
&lt;TD width="40px" height="25px"&gt;&amp;nbsp;&lt;/TD&gt;
&lt;TD width="185.069px" height="25px"&gt;&amp;nbsp;&lt;/TD&gt;
&lt;TD width="169.965px" height="25px"&gt;&amp;nbsp;&lt;/TD&gt;
&lt;/TR&gt;
&lt;TR&gt;
&lt;TD width="185.069px" height="25px"&gt;CCC&lt;/TD&gt;
&lt;TD width="250.885px" height="25px"&gt;CCC&lt;/TD&gt;
&lt;TD width="232.205px" height="25px"&gt;2&lt;/TD&gt;
&lt;TD width="40px" height="25px"&gt;&amp;nbsp;&lt;/TD&gt;
&lt;TD width="40px" height="25px"&gt;&amp;nbsp;&lt;/TD&gt;
&lt;TD width="185.069px" height="25px"&gt;&amp;nbsp;&lt;/TD&gt;
&lt;TD width="169.965px" height="25px"&gt;&amp;nbsp;&lt;/TD&gt;
&lt;/TR&gt;
&lt;TR&gt;
&lt;TD width="185.069px" height="25px"&gt;DDD&lt;/TD&gt;
&lt;TD width="250.885px" height="25px"&gt;DDD&lt;/TD&gt;
&lt;TD width="232.205px" height="25px"&gt;2&lt;/TD&gt;
&lt;TD width="40px" height="25px"&gt;&amp;nbsp;&lt;/TD&gt;
&lt;TD width="40px" height="25px"&gt;&amp;nbsp;&lt;/TD&gt;
&lt;TD width="185.069px" height="25px"&gt;&amp;nbsp;&lt;/TD&gt;
&lt;TD width="169.965px" height="25px"&gt;&amp;nbsp;&lt;/TD&gt;
&lt;/TR&gt;
&lt;TR&gt;
&lt;TD width="185.069px" height="25px"&gt;DDD&lt;/TD&gt;
&lt;TD width="250.885px" height="25px"&gt;EEE&lt;/TD&gt;
&lt;TD width="232.205px" height="25px"&gt;2&lt;/TD&gt;
&lt;TD width="40px" height="25px"&gt;&amp;nbsp;&lt;/TD&gt;
&lt;TD width="40px" height="25px"&gt;&amp;nbsp;&lt;/TD&gt;
&lt;TD width="185.069px" height="25px"&gt;&amp;nbsp;&lt;/TD&gt;
&lt;TD width="169.965px" height="25px"&gt;&amp;nbsp;&lt;/TD&gt;
&lt;/TR&gt;
&lt;TR&gt;
&lt;TD width="185.069px" height="25px"&gt;EEE&lt;/TD&gt;
&lt;TD width="250.885px" height="25px"&gt;DDD&lt;/TD&gt;
&lt;TD width="232.205px" height="25px"&gt;2&lt;/TD&gt;
&lt;TD width="40px" height="25px"&gt;&amp;nbsp;&lt;/TD&gt;
&lt;TD width="40px" height="25px"&gt;&amp;nbsp;&lt;/TD&gt;
&lt;TD width="185.069px" height="25px"&gt;&amp;nbsp;&lt;/TD&gt;
&lt;TD width="169.965px" height="25px"&gt;&amp;nbsp;&lt;/TD&gt;
&lt;/TR&gt;
&lt;TR&gt;
&lt;TD width="185.069px" height="25px"&gt;EEE&lt;/TD&gt;
&lt;TD width="250.885px" height="25px"&gt;EEE&lt;/TD&gt;
&lt;TD width="232.205px" height="25px"&gt;2&lt;/TD&gt;
&lt;TD width="40px" height="25px"&gt;&amp;nbsp;&lt;/TD&gt;
&lt;TD width="40px" height="25px"&gt;&amp;nbsp;&lt;/TD&gt;
&lt;TD width="185.069px" height="25px"&gt;&amp;nbsp;&lt;/TD&gt;
&lt;TD width="169.965px" height="25px"&gt;&amp;nbsp;&lt;/TD&gt;
&lt;/TR&gt;
&lt;/TBODY&gt;
&lt;/TABLE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Next Steps - Generate X map objects that focus on each of the Location_Groups in the table below.&lt;/P&gt;
&lt;P&gt;Thanks in advance&lt;/P&gt;
&lt;P&gt;Tomm&lt;/P&gt;</description>
      <pubDate>Thu, 17 Oct 2024 04:01:50 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/Frontend-Grouping-values-in-a-dynamic-list-into-ordered-unique/m-p/2487531#M101535</guid>
      <dc:creator>Tomm</dc:creator>
      <dc:date>2024-10-17T04:01:50Z</dc:date>
    </item>
    <item>
      <title>Re: Frontend: Grouping values in a dynamic list into ordered unique groups</title>
      <link>https://community.qlik.com/t5/App-Development/Frontend-Grouping-values-in-a-dynamic-list-into-ordered-unique/m-p/2487606#M101542</link>
      <description>&lt;P&gt;&lt;a href="https://community.qlik.com/t5/user/viewprofilepage/user-id/76412"&gt;@Tomm&lt;/a&gt;&amp;nbsp; What is the criteria of selecting Group_1 &amp;amp; Group_2? Example of how you arrived to Group_1 would be helpful to understand logic&lt;/P&gt;</description>
      <pubDate>Thu, 17 Oct 2024 10:08:03 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/Frontend-Grouping-values-in-a-dynamic-list-into-ordered-unique/m-p/2487606#M101542</guid>
      <dc:creator>Kushal_Chawda</dc:creator>
      <dc:date>2024-10-17T10:08:03Z</dc:date>
    </item>
    <item>
      <title>Re: Frontend: Grouping values in a dynamic list into ordered unique groups</title>
      <link>https://community.qlik.com/t5/App-Development/Frontend-Grouping-values-in-a-dynamic-list-into-ordered-unique/m-p/2487625#M101543</link>
      <description>&lt;P&gt;Grouping is done to column A for every member it relates to in column B, I.e AAA is nearby AAA, BBB and CCC so that's group 1.&lt;/P&gt;
&lt;P&gt;BBB is also near AAA and BBB but because its already in group 1 we skip it until we hit a new area thats ungrouped. In my example thats DDD.&lt;/P&gt;
&lt;P&gt;The order this occurs conceptually is based on how many other areas are 'nearby' forming the biggest group first and so on.&lt;/P&gt;</description>
      <pubDate>Fri, 18 Oct 2024 02:08:44 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/Frontend-Grouping-values-in-a-dynamic-list-into-ordered-unique/m-p/2487625#M101543</guid>
      <dc:creator>Tomm</dc:creator>
      <dc:date>2024-10-18T02:08:44Z</dc:date>
    </item>
    <item>
      <title>Re: Frontend: Grouping values in a dynamic list into ordered unique groups</title>
      <link>https://community.qlik.com/t5/App-Development/Frontend-Grouping-values-in-a-dynamic-list-into-ordered-unique/m-p/2487629#M101544</link>
      <description>&lt;P&gt;&lt;a href="https://community.qlik.com/t5/user/viewprofilepage/user-id/76412"&gt;@Tomm&lt;/a&gt;&amp;nbsp; is the count_near_by_location is the direct field or calculated field? Also, Why not DDD &amp;amp; EEE in group 1?&lt;/P&gt;</description>
      <pubDate>Thu, 17 Oct 2024 11:53:09 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/Frontend-Grouping-values-in-a-dynamic-list-into-ordered-unique/m-p/2487629#M101544</guid>
      <dc:creator>Kushal_Chawda</dc:creator>
      <dc:date>2024-10-17T11:53:09Z</dc:date>
    </item>
    <item>
      <title>Re: Frontend: Grouping values in a dynamic list into ordered unique groups</title>
      <link>https://community.qlik.com/t5/App-Development/Frontend-Grouping-values-in-a-dynamic-list-into-ordered-unique/m-p/2487644#M101545</link>
      <description>&lt;P&gt;Calculate field, DDD &amp;amp; EEE are not 'nearby' AAA. nearby is precalculated.&lt;/P&gt;</description>
      <pubDate>Thu, 17 Oct 2024 12:10:13 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/Frontend-Grouping-values-in-a-dynamic-list-into-ordered-unique/m-p/2487644#M101545</guid>
      <dc:creator>Tomm</dc:creator>
      <dc:date>2024-10-17T12:10:13Z</dc:date>
    </item>
  </channel>
</rss>

