<?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 Set Analysis - Referencing to Values in selected set in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/Set-Analysis-Referencing-to-Values-in-selected-set/m-p/1035184#M639591</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;H4 style="font-size: 13.3333px;"&gt;&lt;SPAN style="line-height: 1.5em; font-size: 12pt;"&gt;tl;dr:&lt;/SPAN&gt;&lt;/H4&gt;&lt;P style="font-size: 13.3333px;"&gt;I make a selection of Dates with Set Analysis. I want to reference to each of the values within the selection. But QV only references to the min-Value of the selection.&lt;/P&gt;&lt;H4&gt;&lt;/H4&gt;&lt;H4&gt;&lt;SPAN style="font-size: 12pt;"&gt;The whole story:&lt;/SPAN&gt;&lt;/H4&gt;&lt;P&gt;Hi everyone,&lt;/P&gt;&lt;P&gt;I'm currently struggling a little with set analysis and would appreciate your help.&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;&lt;BR /&gt;&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;The use case:&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;I have several campaigns. There can be one or more campaigns every day. I want to show the user the conversion rates of these campaigns. The user can choose a timeframe. Every campaign from within that timeframe should be displayed. The user can also select a runtime, which tells him about the conversion rate after X days.&lt;/P&gt;&lt;P&gt;In one sentence one could say:&lt;SPAN style="text-decoration: underline;"&gt; Show me the conversion rate of all my selected campaigns after X days.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;To display this conversion rate I created an expression and I'm working with set analysis:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE __default_attr="plain" __jive_macro_name="code" class="jive_macro_code jive_text_macro _jivemacro_uid_14564712889543620" jivemacro_uid="_14564712889543620"&gt;
&lt;P&gt;count(DISTINCT {$&amp;lt;Runtime={$(vSelectedRuntime)}, Dates={"&amp;gt;=$(=Date(Min(SelectedDates))) &amp;lt;=$(=Date(Num(Min(SelectedDates))+$(vSelectedRuntime)-1))"},&lt;/P&gt;
&lt;P&gt;&amp;nbsp; x={'SomeParameter'}, SelectedDates=, y= &amp;gt;} CustomerID)&lt;/P&gt;
&lt;P&gt;/ count(DISTINCT {$&amp;lt;Runtime={$(vSelectedRuntime)}, x={'SomeParameter} &amp;gt;} CustomerID)&lt;/P&gt;

&lt;/PRE&gt;&lt;P&gt;Putting this into words one could say:&lt;/P&gt;&lt;P&gt;Count all new customers we gained with this campaign after X days and divide them by the number of people we approached. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Let's assume every campaign has a conversion rate of 10% for our selected runtime. Then the result should look something like:&lt;/P&gt;&lt;P&gt;Camp1Date1-10%&lt;/P&gt;&lt;P&gt;Camp2Date1-10%&lt;/P&gt;&lt;P&gt;Camp1Date2-10%&lt;/P&gt;&lt;P&gt;Camp1Date3-10%&lt;/P&gt;&lt;P&gt;Camp1Date4-10%&lt;/P&gt;&lt;P&gt;...&lt;/P&gt;&lt;P&gt;But unfortunately the result looks like:&lt;/P&gt;&lt;P&gt;Camp1Date1-10%&lt;/P&gt;&lt;P&gt;Camp2Date1-10%&lt;/P&gt;&lt;P&gt;Camp1Date2-7%&lt;/P&gt;&lt;P&gt;Camp1Date3-3%&lt;/P&gt;&lt;P&gt;Camp1Date4-0%&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;So, the result for the first date is correct. All the other results are not correct.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The problem is, that QV starts the calculation of the Conversion rate for every campaign at min(SelectedDates). It should start calculations at the associated date for each campaign in SelectedDates.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I would really appreciate your help. If there is anything left unclear after this wall of text, feel free to ask.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Fri, 26 Feb 2016 08:22:58 GMT</pubDate>
    <dc:creator>ottebian</dc:creator>
    <dc:date>2016-02-26T08:22:58Z</dc:date>
    <item>
      <title>Set Analysis - Referencing to Values in selected set</title>
      <link>https://community.qlik.com/t5/QlikView/Set-Analysis-Referencing-to-Values-in-selected-set/m-p/1035184#M639591</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;H4 style="font-size: 13.3333px;"&gt;&lt;SPAN style="line-height: 1.5em; font-size: 12pt;"&gt;tl;dr:&lt;/SPAN&gt;&lt;/H4&gt;&lt;P style="font-size: 13.3333px;"&gt;I make a selection of Dates with Set Analysis. I want to reference to each of the values within the selection. But QV only references to the min-Value of the selection.&lt;/P&gt;&lt;H4&gt;&lt;/H4&gt;&lt;H4&gt;&lt;SPAN style="font-size: 12pt;"&gt;The whole story:&lt;/SPAN&gt;&lt;/H4&gt;&lt;P&gt;Hi everyone,&lt;/P&gt;&lt;P&gt;I'm currently struggling a little with set analysis and would appreciate your help.&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;&lt;BR /&gt;&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;The use case:&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;I have several campaigns. There can be one or more campaigns every day. I want to show the user the conversion rates of these campaigns. The user can choose a timeframe. Every campaign from within that timeframe should be displayed. The user can also select a runtime, which tells him about the conversion rate after X days.&lt;/P&gt;&lt;P&gt;In one sentence one could say:&lt;SPAN style="text-decoration: underline;"&gt; Show me the conversion rate of all my selected campaigns after X days.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;To display this conversion rate I created an expression and I'm working with set analysis:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE __default_attr="plain" __jive_macro_name="code" class="jive_macro_code jive_text_macro _jivemacro_uid_14564712889543620" jivemacro_uid="_14564712889543620"&gt;
&lt;P&gt;count(DISTINCT {$&amp;lt;Runtime={$(vSelectedRuntime)}, Dates={"&amp;gt;=$(=Date(Min(SelectedDates))) &amp;lt;=$(=Date(Num(Min(SelectedDates))+$(vSelectedRuntime)-1))"},&lt;/P&gt;
&lt;P&gt;&amp;nbsp; x={'SomeParameter'}, SelectedDates=, y= &amp;gt;} CustomerID)&lt;/P&gt;
&lt;P&gt;/ count(DISTINCT {$&amp;lt;Runtime={$(vSelectedRuntime)}, x={'SomeParameter} &amp;gt;} CustomerID)&lt;/P&gt;

&lt;/PRE&gt;&lt;P&gt;Putting this into words one could say:&lt;/P&gt;&lt;P&gt;Count all new customers we gained with this campaign after X days and divide them by the number of people we approached. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Let's assume every campaign has a conversion rate of 10% for our selected runtime. Then the result should look something like:&lt;/P&gt;&lt;P&gt;Camp1Date1-10%&lt;/P&gt;&lt;P&gt;Camp2Date1-10%&lt;/P&gt;&lt;P&gt;Camp1Date2-10%&lt;/P&gt;&lt;P&gt;Camp1Date3-10%&lt;/P&gt;&lt;P&gt;Camp1Date4-10%&lt;/P&gt;&lt;P&gt;...&lt;/P&gt;&lt;P&gt;But unfortunately the result looks like:&lt;/P&gt;&lt;P&gt;Camp1Date1-10%&lt;/P&gt;&lt;P&gt;Camp2Date1-10%&lt;/P&gt;&lt;P&gt;Camp1Date2-7%&lt;/P&gt;&lt;P&gt;Camp1Date3-3%&lt;/P&gt;&lt;P&gt;Camp1Date4-0%&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;So, the result for the first date is correct. All the other results are not correct.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The problem is, that QV starts the calculation of the Conversion rate for every campaign at min(SelectedDates). It should start calculations at the associated date for each campaign in SelectedDates.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I would really appreciate your help. If there is anything left unclear after this wall of text, feel free to ask.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 26 Feb 2016 08:22:58 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Set-Analysis-Referencing-to-Values-in-selected-set/m-p/1035184#M639591</guid>
      <dc:creator>ottebian</dc:creator>
      <dc:date>2016-02-26T08:22:58Z</dc:date>
    </item>
  </channel>
</rss>

