<?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 Creating truncated reference lines in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/Creating-truncated-reference-lines/m-p/1772071#M717255</link>
    <description>&lt;P&gt;Hi All,&lt;/P&gt;&lt;P&gt;I have created truncated reference lines for several items that I have plotted on a time series chart. Plotting each item separately (e.g. Fig 1&amp;nbsp; below) works OK but when I try to select all items the truncated reference line does not look right.&lt;/P&gt;&lt;P&gt;I have attached an example QlikView file and data file.&lt;/P&gt;&lt;P&gt;Appreciate any help you can provide.&lt;/P&gt;&lt;P&gt;Fig. 1&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="cgaleaQlik_1-1609887978324.png" style="width: 400px;"&gt;&lt;img src="https://community.qlik.com/t5/image/serverpage/image-id/46463iBE0D49F780987CAA/image-size/medium?v=v2&amp;amp;px=400" role="button" title="cgaleaQlik_1-1609887978324.png" alt="cgaleaQlik_1-1609887978324.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Fig. 2&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="cgaleaQlik_2-1609888026895.png" style="width: 400px;"&gt;&lt;img src="https://community.qlik.com/t5/image/serverpage/image-id/46464i3FC5DF584589B6B4/image-size/medium?v=v2&amp;amp;px=400" role="button" title="cgaleaQlik_2-1609888026895.png" alt="cgaleaQlik_2-1609888026895.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;Thank you,&lt;/P&gt;&lt;P&gt;Charles&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Tue, 05 Jan 2021 23:09:22 GMT</pubDate>
    <dc:creator>cgaleaQlik</dc:creator>
    <dc:date>2021-01-05T23:09:22Z</dc:date>
    <item>
      <title>Creating truncated reference lines</title>
      <link>https://community.qlik.com/t5/QlikView/Creating-truncated-reference-lines/m-p/1772071#M717255</link>
      <description>&lt;P&gt;Hi All,&lt;/P&gt;&lt;P&gt;I have created truncated reference lines for several items that I have plotted on a time series chart. Plotting each item separately (e.g. Fig 1&amp;nbsp; below) works OK but when I try to select all items the truncated reference line does not look right.&lt;/P&gt;&lt;P&gt;I have attached an example QlikView file and data file.&lt;/P&gt;&lt;P&gt;Appreciate any help you can provide.&lt;/P&gt;&lt;P&gt;Fig. 1&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="cgaleaQlik_1-1609887978324.png" style="width: 400px;"&gt;&lt;img src="https://community.qlik.com/t5/image/serverpage/image-id/46463iBE0D49F780987CAA/image-size/medium?v=v2&amp;amp;px=400" role="button" title="cgaleaQlik_1-1609887978324.png" alt="cgaleaQlik_1-1609887978324.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Fig. 2&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="cgaleaQlik_2-1609888026895.png" style="width: 400px;"&gt;&lt;img src="https://community.qlik.com/t5/image/serverpage/image-id/46464i3FC5DF584589B6B4/image-size/medium?v=v2&amp;amp;px=400" role="button" title="cgaleaQlik_2-1609888026895.png" alt="cgaleaQlik_2-1609888026895.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;Thank you,&lt;/P&gt;&lt;P&gt;Charles&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 05 Jan 2021 23:09:22 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Creating-truncated-reference-lines/m-p/1772071#M717255</guid>
      <dc:creator>cgaleaQlik</dc:creator>
      <dc:date>2021-01-05T23:09:22Z</dc:date>
    </item>
    <item>
      <title>Re: Creating truncated reference lines</title>
      <link>https://community.qlik.com/t5/QlikView/Creating-truncated-reference-lines/m-p/1772501#M717256</link>
      <description>&lt;P&gt;Hi Charles.&lt;/P&gt;&lt;P&gt;I've modified yours expression to:&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;if(wildmatch(GetFieldSelections(Item), 'A*') and Date &amp;lt; '01 Jul 2020', 5,
if(wildmatch(GetFieldSelections(Item), '*B*') and Date &amp;lt; '01 Jul 2020', 3,
if(wildmatch(GetFieldSelections(Item), '*C*') and Date &amp;lt; '01 Jul 2020', 1,
if(wildmatch(GetFieldSelections(Item), '*D*') and Date &amp;lt; '01 Jul 2020', 2.5,
if((
	match(GetFieldSelections(Item,','), 'A,B,C,D') 
	or
	len(GetFieldSelections(Item)) &amp;lt; 1
) 
	and Date &amp;lt; '01 Jul 2020', 10, 0)))))&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;It's not perfect becease will work properly only when you select on Item listbox: one value, all values or leave it empty. Please read&amp;nbsp; GetFieldSelections() documentation before work with wider set of items. Calculated 'Reference lines' should use agregating function like sum().&amp;nbsp;&lt;/P&gt;&lt;P&gt;I suggest you to add reference value to script data, Ref_Lines_Data.xlsx as a values to sum. Will be easier to create a valid expression.&lt;/P&gt;</description>
      <pubDate>Thu, 07 Jan 2021 11:16:55 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Creating-truncated-reference-lines/m-p/1772501#M717256</guid>
      <dc:creator>mfchmielowski</dc:creator>
      <dc:date>2021-01-07T11:16:55Z</dc:date>
    </item>
    <item>
      <title>Re: Creating truncated reference lines</title>
      <link>https://community.qlik.com/t5/QlikView/Creating-truncated-reference-lines/m-p/1772748#M717257</link>
      <description>&lt;P&gt;Great, looks like it will help for now. Appreciate your help!!!&lt;/P&gt;</description>
      <pubDate>Thu, 07 Jan 2021 21:53:35 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Creating-truncated-reference-lines/m-p/1772748#M717257</guid>
      <dc:creator>cgaleaQlik</dc:creator>
      <dc:date>2021-01-07T21:53:35Z</dc:date>
    </item>
  </channel>
</rss>

