<?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 Conditional color based on % to Total in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/Conditional-color-based-on-to-Total/m-p/291452#M587240</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;What is your expression?&amp;nbsp; How is the chart defined?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Wed, 15 Jun 2011 17:16:12 GMT</pubDate>
    <dc:creator>johnw</dc:creator>
    <dc:date>2011-06-15T17:16:12Z</dc:date>
    <item>
      <title>Conditional color based on % to Total</title>
      <link>https://community.qlik.com/t5/QlikView/Conditional-color-based-on-to-Total/m-p/291451#M587239</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I am able to get the % to total values to display properly in my pivot table.&amp;nbsp; Now, I would like to display the following background color formatting as it is in Excel.&amp;nbsp; ([PS Department Group] and [KPI Month] (going across) are both dimensions.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Red where the % for individual month is less than TOTAL % for all months.&lt;/P&gt;&lt;P&gt;Green where the % for individual month is greater than TOTAL % for all months.﻿﻿&lt;/P&gt;&lt;P&gt;&lt;IMG alt="Conditional Color.gif" class="jive-image-thumbnail jive-image" height="423" onclick="" src="https://community.qlik.com/legacyfs/online/5237_Conditional+Color.gif" width="461" /&gt;&lt;/P&gt;&lt;P&gt;Any help is greatly appreciated!&lt;/P&gt;&lt;P&gt;Thanks,&lt;/P&gt;&lt;P&gt;Dan&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 15 Jun 2011 16:46:03 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Conditional-color-based-on-to-Total/m-p/291451#M587239</guid>
      <dc:creator>dwh1104</dc:creator>
      <dc:date>2011-06-15T16:46:03Z</dc:date>
    </item>
    <item>
      <title>Conditional color based on % to Total</title>
      <link>https://community.qlik.com/t5/QlikView/Conditional-color-based-on-to-Total/m-p/291452#M587240</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;What is your expression?&amp;nbsp; How is the chart defined?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 15 Jun 2011 17:16:12 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Conditional-color-based-on-to-Total/m-p/291452#M587240</guid>
      <dc:creator>johnw</dc:creator>
      <dc:date>2011-06-15T17:16:12Z</dc:date>
    </item>
    <item>
      <title>Conditional color based on % to Total</title>
      <link>https://community.qlik.com/t5/QlikView/Conditional-color-based-on-to-Total/m-p/291453#M587241</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;&lt;SPAN style="color: #0000ff; font-size: 10pt;"&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 10pt; color: black;"&gt;If(GetCurrentField([Date Comparison])='KPI Event Month' &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 10pt; color: black;"&gt;sum({&amp;lt;KPI={'Visit Encounters'},&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 10pt; color: black;"&gt;[KPI Event Year]={$(=Only([KPI Event Year]))}&amp;gt;}[KPI Amount])/&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 10pt; color: black;"&gt;sum({&amp;lt;KPI={'Visit Encounters'},&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 10pt; color: black;"&gt;[KPI Event Year]={$(=Only([KPI Event Year]))}&amp;gt;}TOTAL&amp;lt;[KPI Event Month],[KPI Forecast Unit Short]&amp;gt;[KPI Amount]),&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 10pt; color: black;"&gt; &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 10pt; color: black;"&gt;If(GetCurrentField([Date Comparison])='KPI Event Quarter',&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 10pt; color: black;"&gt;sum({&amp;lt;KPI={'Visit Encounters'},&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 10pt; color: black;"&gt;[KPI Event Year]={$(=Only([KPI Event Year]))}&amp;gt;}[KPI Amount])/&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 10pt; color: black;"&gt;sum({&amp;lt;KPI={'Visit Encounters'},&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 10pt; color: black;"&gt;[KPI Event Year]={$(=Only([KPI Event Year]))}&amp;gt;}TOTAL&amp;lt;[KPI Event Quarter],[KPI Forecast Unit&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 10pt; color: black;"&gt;Short]&amp;gt;[KPI Amount])))&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 15 Jun 2011 17:24:16 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Conditional-color-based-on-to-Total/m-p/291453#M587241</guid>
      <dc:creator>dwh1104</dc:creator>
      <dc:date>2011-06-15T17:24:16Z</dc:date>
    </item>
    <item>
      <title>Conditional color based on % to Total</title>
      <link>https://community.qlik.com/t5/QlikView/Conditional-color-based-on-to-Total/m-p/291454#M587242</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Apply your conditions as Background Colour, you find it under Properties - Expressions and then open the small "+"-sign.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;HTH&lt;BR /&gt;Peter&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 15 Jun 2011 21:32:25 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Conditional-color-based-on-to-Total/m-p/291454#M587242</guid>
      <dc:creator>prieper</dc:creator>
      <dc:date>2011-06-15T21:32:25Z</dc:date>
    </item>
    <item>
      <title>Conditional color based on % to Total</title>
      <link>https://community.qlik.com/t5/QlikView/Conditional-color-based-on-to-Total/m-p/291455#M587243</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt; Peter,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I know how the colored background works...What I need help with is getting the colors to show up based on each month's % to Total compared to ALL month's % to Total.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks,&lt;/P&gt;&lt;P&gt;Dan&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 16 Jun 2011 13:06:48 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Conditional-color-based-on-to-Total/m-p/291455#M587243</guid>
      <dc:creator>dwh1104</dc:creator>
      <dc:date>2011-06-16T13:06:48Z</dc:date>
    </item>
    <item>
      <title>Conditional color based on % to Total</title>
      <link>https://community.qlik.com/t5/QlikView/Conditional-color-based-on-to-Total/m-p/291456#M587244</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt; you can use the functions Dimensionality() OR ColumnNo() to calculate the Column total for each Column.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Ex.: IF(Dimensionality() &amp;lt;&amp;gt; 0, SUM(Values)/100, &amp;lt;new_expression&amp;gt;)&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 16 Jun 2011 14:53:21 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Conditional-color-based-on-to-Total/m-p/291456#M587244</guid>
      <dc:creator />
      <dc:date>2011-06-16T14:53:21Z</dc:date>
    </item>
    <item>
      <title>Re: Conditional color based on % to Total</title>
      <link>https://community.qlik.com/t5/QlikView/Conditional-color-based-on-to-Total/m-p/291457#M587245</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Dimensionality() and Column() will not help me, because the Month going across is actually a dimension.&amp;nbsp; (There is not a separate expression for each month.)&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 16 Jun 2011 16:12:26 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Conditional-color-based-on-to-Total/m-p/291457#M587245</guid>
      <dc:creator>dwh1104</dc:creator>
      <dc:date>2011-06-16T16:12:26Z</dc:date>
    </item>
    <item>
      <title>Re: Conditional color based on % to Total</title>
      <link>https://community.qlik.com/t5/QlikView/Conditional-color-based-on-to-Total/m-p/291458#M587246</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I understand but the function dimensionality() return the value "0" when the column is "TOTAL"&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;You can use to calculate the total for each row. See this example;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 16 Jun 2011 17:47:19 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Conditional-color-based-on-to-Total/m-p/291458#M587246</guid>
      <dc:creator />
      <dc:date>2011-06-16T17:47:19Z</dc:date>
    </item>
    <item>
      <title>Re: Conditional color based on % to Total</title>
      <link>https://community.qlik.com/t5/QlikView/Conditional-color-based-on-to-Total/m-p/291459#M587247</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Eduardo,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I can see how this has the potential to work.&amp;nbsp; Now I know the difference between Column() and ColumnNo() and how it can be used.&amp;nbsp; Thanks!&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Now I just need to figure out how to apply it to my issue.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If you could help decipher what the following expression is doing, it would be a great help.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG style=": ; color: #0000ff; font-size: 10pt;"&gt;&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 11pt; color: black; font-family: 'Calibri','sans-serif';"&gt;IF(Sum(Value) &amp;lt; Last(RANGESUM(Before(SUM(Value),0,ColumnNo()))) / COUNT(Total Distinct Date), RGB(255,0,0),&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 11pt; color: black; font-family: 'Calibri','sans-serif';"&gt;&amp;nbsp; IF(Sum(Value) &amp;gt; Last(RANGESUM(Before(SUM(Value),0,ColumnNo()))) / COUNT(Total Distinct Date), RGB(0,255,0)))&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG style=": ; color: #ff0000; font-size: 10pt;"&gt; &lt;/STRONG&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 17 Jun 2011 18:23:28 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Conditional-color-based-on-to-Total/m-p/291459#M587247</guid>
      <dc:creator>dwh1104</dc:creator>
      <dc:date>2011-06-17T18:23:28Z</dc:date>
    </item>
    <item>
      <title>Re: Conditional color based on % to Total</title>
      <link>https://community.qlik.com/t5/QlikView/Conditional-color-based-on-to-Total/m-p/291460#M587248</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt; Hi,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The sintaxe "RANGESUM(Before(SUM(Value),0,ColumnNo() ) )" return the value acumulate for each column:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;30&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 65&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 30&amp;nbsp; -&amp;gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;STRONG&gt; 30&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 95&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 125&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The function "LAST()" replicate the last value for each row: &lt;STRONG&gt;125&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt; &lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;COUNT(Total Distinct Date): returns the number of month (column) because we need to calculate the avg for all value in the table:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;"41,666666"&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;After just need to verify the valeu with this result to demonstrate the color that you want:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;IF 30 &amp;gt; 41,666666 return GREEN()&lt;/P&gt;&lt;P&gt;IF 30 &amp;lt; 41,666666 return RED()&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 20 Jun 2011 13:28:07 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Conditional-color-based-on-to-Total/m-p/291460#M587248</guid>
      <dc:creator />
      <dc:date>2011-06-20T13:28:07Z</dc:date>
    </item>
    <item>
      <title>Re: Conditional color based on % to Total</title>
      <link>https://community.qlik.com/t5/QlikView/Conditional-color-based-on-to-Total/m-p/291461#M587249</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thanks Eduardo.&amp;nbsp; I was able to work out the background color expression for my issue, based on the expression you provided.&lt;IMG src="https://community.qlik.com/legacyfs/online/emoticons/cool.png" /&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 20 Jun 2011 16:15:44 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Conditional-color-based-on-to-Total/m-p/291461#M587249</guid>
      <dc:creator>dwh1104</dc:creator>
      <dc:date>2011-06-20T16:15:44Z</dc:date>
    </item>
  </channel>
</rss>

