<?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: Performance Matrix Sales and Margin in App Development</title>
    <link>https://community.qlik.com/t5/App-Development/Performance-Matrix-Sales-and-Margin/m-p/1813563#M66441</link>
    <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://community.qlik.com/t5/user/viewprofilepage/user-id/28968"&gt;@chrismarlow&lt;/a&gt;&amp;nbsp;,&lt;/P&gt;&lt;P&gt;Thanks a lot for your fast reply, highly appreciate!&lt;/P&gt;&lt;P&gt;The second suggestion would not work, as the bonuses are not mirrored. However, the first approach with pack and match is indeed working. I though used it a little differently, as I'm not aiming to perfectly match the value but to find it within an interval. Therefore I combined your proposal with this one: &lt;A href="https://community.qlik.com/t5/QlikView-App-Dev/Pick-and-Match-function/td-p/1328755" target="_self"&gt;Pick Match Intervals&lt;/A&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;All in all, that's how it turned out to work:&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;pick(match(-1, margin&amp;lt;50, margin &amp;gt;= 50 and margin &amp;lt; 52,margin &amp;gt;= 52 and margin &amp;lt;54,margin &amp;gt;=54 and margin &amp;lt;56, margin &amp;gt;=56 and margin &amp;lt;58,margin &amp;gt;=58 and margin &amp;lt;60, margin &amp;gt;=60), 
    pick(match(-1, sales &amp;lt;10, sales &amp;gt;=10 and sales &amp;gt; 12, sales &amp;gt;=12 and sales &amp;lt; 14,sales &amp;gt;=14 and sales &amp;lt; 16, sales &amp;gt;=16 and sales &amp;lt;18, sales &amp;gt;=18),0,0,10,20,30,40),
  pick(match(-1, sales &amp;lt;10, sales &amp;gt;=10 and sales &amp;gt; 12, sales &amp;gt;=12 and sales &amp;lt; 14,sales &amp;gt;=14 and sales &amp;lt; 16, sales &amp;gt;=16 and sales &amp;lt;18, sales &amp;gt;=18),0,0,10,20,30,40),
  pick(match(-1, sales &amp;lt;10, sales &amp;gt;=10 and sales &amp;gt; 12, sales &amp;gt;=12 and sales &amp;lt; 14,sales &amp;gt;=14 and sales &amp;lt; 16, sales &amp;gt;=16 and sales &amp;lt;18, sales &amp;gt;=18),10,10,20,30,40,50),
  pick(match(-1, sales &amp;lt;10, sales &amp;gt;=10 and sales &amp;gt; 12, sales &amp;gt;=12 and sales &amp;lt; 14,sales &amp;gt;=14 and sales &amp;lt; 16, sales &amp;gt;=16 and sales &amp;lt;18, sales &amp;gt;=18),20,20,30,40,50,60),
  pick(match(-1, sales &amp;lt;10, sales &amp;gt;=10 and sales &amp;gt; 12, sales &amp;gt;=12 and sales &amp;lt; 14,sales &amp;gt;=14 and sales &amp;lt; 16, sales &amp;gt;=16 and sales &amp;lt;18, sales &amp;gt;=18),30,30,40,50,60,70),    
  pick(match(-1, sales &amp;lt;10, sales &amp;gt;=10 and sales &amp;gt; 12, sales &amp;gt;=12 and sales &amp;lt; 14,sales &amp;gt;=14 and sales &amp;lt; 16, sales &amp;gt;=16 and sales &amp;lt;18, sales &amp;gt;=18),40,40,50,60,70,80),    
  pick(match(-1, sales &amp;lt;10, sales &amp;gt;=10 and sales &amp;gt; 12, sales &amp;gt;=12 and sales &amp;lt; 14,sales &amp;gt;=14 and sales &amp;lt; 16, sales &amp;gt;=16 and sales &amp;lt;18, sales &amp;gt;=18),50,50,60,70,80,100))&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Tue, 08 Jun 2021 08:58:29 GMT</pubDate>
    <dc:creator>charlie2</dc:creator>
    <dc:date>2021-06-08T08:58:29Z</dc:date>
    <item>
      <title>Performance Matrix Sales and Margin</title>
      <link>https://community.qlik.com/t5/App-Development/Performance-Matrix-Sales-and-Margin/m-p/1813405#M66416</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;I have a Matrix with the sales and margin's goals of the sales reps and the corresponding bonus. My idea is to show the monthly bonus a sales rep would have according to his/her YTD performance (by extrapolating sales and margin, for example).&amp;nbsp;&lt;/P&gt;&lt;P&gt;A simpler version of the matrix looks like that, with the x-axis containing the sales objectives and the y-axis the margins goal:&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="charlie2_0-1623072553509.png" style="width: 400px;"&gt;&lt;img src="https://community.qlik.com/t5/image/serverpage/image-id/56430iE003F6D8F3D69C1D/image-size/medium?v=v2&amp;amp;px=400" role="button" title="charlie2_0-1623072553509.png" alt="charlie2_0-1623072553509.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;So far I did:&lt;/P&gt;&lt;P&gt;- Convert the matrix into a table&lt;/P&gt;&lt;P&gt;- Create a master element with if statements to return the bonus%. This is very inefficient plus since the matrix is way larger than this one, it turns out to be not possible, as it would need more than 100 if statements.&lt;/P&gt;&lt;P&gt;Any suggestion on how to calculate such KPI directly as a master element (not in the data editor)?&lt;/P&gt;&lt;P&gt;Thanks a lot in advance&lt;/P&gt;</description>
      <pubDate>Mon, 07 Jun 2021 13:31:01 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/Performance-Matrix-Sales-and-Margin/m-p/1813405#M66416</guid>
      <dc:creator>charlie2</dc:creator>
      <dc:date>2021-06-07T13:31:01Z</dc:date>
    </item>
    <item>
      <title>Re: Performance Matrix Sales and Margin</title>
      <link>https://community.qlik.com/t5/App-Development/Performance-Matrix-Sales-and-Margin/m-p/1813452#M66425</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;I am guessing that your actual matrix cannot be expressed as a formula in the way your example can be (see below)? If it can then you should be able to do similar in Qlik.&lt;/P&gt;&lt;P&gt;If it cannot you can try pick/match, you may need to round your sales/margin figures somehow to feed this, but would look something like the below for your example grid;&lt;/P&gt;&lt;LI-CODE lang="javascript"&gt;pick(match(margin,50,52,54,56,58,60), 
	pick(match(sales,10,12,14,16,18),0,10,20,30,40),
    pick(match(sales,10,12,14,16,18),10,20,30,40,50),
    pick(match(sales,10,12,14,16,18),20,30,40,50,60),
    pick(match(sales,10,12,14,16,18),30,40,50,60,70),
    pick(match(sales,10,12,14,16,18),40,50,60,70,80), 
    pick(match(sales,10,12,14,16,18),50,60,70,80,100))&lt;/LI-CODE&gt;&lt;P&gt;It will probably be easier to build the pick/match in Excel &amp;amp; copy paste in rather than try typing in via the UI (the same would go if you continued with embedded if statements, not tried it in Qlik Sense by QlikView would tolerate quite long formulae).&lt;/P&gt;&lt;P&gt;Cheers,&lt;/P&gt;&lt;P&gt;Chris.&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="20210607_1.png" style="width: 991px;"&gt;&lt;img src="https://community.qlik.com/t5/image/serverpage/image-id/56445iEA0B0C99913805EF/image-size/large?v=v2&amp;amp;px=999" role="button" title="20210607_1.png" alt="20210607_1.png" /&gt;&lt;/span&gt;&lt;/P&gt;</description>
      <pubDate>Mon, 07 Jun 2021 17:07:59 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/Performance-Matrix-Sales-and-Margin/m-p/1813452#M66425</guid>
      <dc:creator>chrismarlow</dc:creator>
      <dc:date>2021-06-07T17:07:59Z</dc:date>
    </item>
    <item>
      <title>Re: Performance Matrix Sales and Margin</title>
      <link>https://community.qlik.com/t5/App-Development/Performance-Matrix-Sales-and-Margin/m-p/1813563#M66441</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://community.qlik.com/t5/user/viewprofilepage/user-id/28968"&gt;@chrismarlow&lt;/a&gt;&amp;nbsp;,&lt;/P&gt;&lt;P&gt;Thanks a lot for your fast reply, highly appreciate!&lt;/P&gt;&lt;P&gt;The second suggestion would not work, as the bonuses are not mirrored. However, the first approach with pack and match is indeed working. I though used it a little differently, as I'm not aiming to perfectly match the value but to find it within an interval. Therefore I combined your proposal with this one: &lt;A href="https://community.qlik.com/t5/QlikView-App-Dev/Pick-and-Match-function/td-p/1328755" target="_self"&gt;Pick Match Intervals&lt;/A&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;All in all, that's how it turned out to work:&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;pick(match(-1, margin&amp;lt;50, margin &amp;gt;= 50 and margin &amp;lt; 52,margin &amp;gt;= 52 and margin &amp;lt;54,margin &amp;gt;=54 and margin &amp;lt;56, margin &amp;gt;=56 and margin &amp;lt;58,margin &amp;gt;=58 and margin &amp;lt;60, margin &amp;gt;=60), 
    pick(match(-1, sales &amp;lt;10, sales &amp;gt;=10 and sales &amp;gt; 12, sales &amp;gt;=12 and sales &amp;lt; 14,sales &amp;gt;=14 and sales &amp;lt; 16, sales &amp;gt;=16 and sales &amp;lt;18, sales &amp;gt;=18),0,0,10,20,30,40),
  pick(match(-1, sales &amp;lt;10, sales &amp;gt;=10 and sales &amp;gt; 12, sales &amp;gt;=12 and sales &amp;lt; 14,sales &amp;gt;=14 and sales &amp;lt; 16, sales &amp;gt;=16 and sales &amp;lt;18, sales &amp;gt;=18),0,0,10,20,30,40),
  pick(match(-1, sales &amp;lt;10, sales &amp;gt;=10 and sales &amp;gt; 12, sales &amp;gt;=12 and sales &amp;lt; 14,sales &amp;gt;=14 and sales &amp;lt; 16, sales &amp;gt;=16 and sales &amp;lt;18, sales &amp;gt;=18),10,10,20,30,40,50),
  pick(match(-1, sales &amp;lt;10, sales &amp;gt;=10 and sales &amp;gt; 12, sales &amp;gt;=12 and sales &amp;lt; 14,sales &amp;gt;=14 and sales &amp;lt; 16, sales &amp;gt;=16 and sales &amp;lt;18, sales &amp;gt;=18),20,20,30,40,50,60),
  pick(match(-1, sales &amp;lt;10, sales &amp;gt;=10 and sales &amp;gt; 12, sales &amp;gt;=12 and sales &amp;lt; 14,sales &amp;gt;=14 and sales &amp;lt; 16, sales &amp;gt;=16 and sales &amp;lt;18, sales &amp;gt;=18),30,30,40,50,60,70),    
  pick(match(-1, sales &amp;lt;10, sales &amp;gt;=10 and sales &amp;gt; 12, sales &amp;gt;=12 and sales &amp;lt; 14,sales &amp;gt;=14 and sales &amp;lt; 16, sales &amp;gt;=16 and sales &amp;lt;18, sales &amp;gt;=18),40,40,50,60,70,80),    
  pick(match(-1, sales &amp;lt;10, sales &amp;gt;=10 and sales &amp;gt; 12, sales &amp;gt;=12 and sales &amp;lt; 14,sales &amp;gt;=14 and sales &amp;lt; 16, sales &amp;gt;=16 and sales &amp;lt;18, sales &amp;gt;=18),50,50,60,70,80,100))&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 08 Jun 2021 08:58:29 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/Performance-Matrix-Sales-and-Margin/m-p/1813563#M66441</guid>
      <dc:creator>charlie2</dc:creator>
      <dc:date>2021-06-08T08:58:29Z</dc:date>
    </item>
    <item>
      <title>Re: Performance Matrix Sales and Margin</title>
      <link>https://community.qlik.com/t5/App-Development/Performance-Matrix-Sales-and-Margin/m-p/1813564#M66442</link>
      <description>&lt;P&gt;That is a neat one, thanks for sharing back I will store that one away in the memory banks.&lt;/P&gt;&lt;P&gt;Cheers, Chris.&lt;/P&gt;</description>
      <pubDate>Tue, 08 Jun 2021 09:02:25 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/Performance-Matrix-Sales-and-Margin/m-p/1813564#M66442</guid>
      <dc:creator>chrismarlow</dc:creator>
      <dc:date>2021-06-08T09:02:25Z</dc:date>
    </item>
  </channel>
</rss>

