<?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 RGB as a data type - importing /  applying RGB to Dimensions /  Measures in App Development</title>
    <link>https://community.qlik.com/t5/App-Development/RGB-as-a-data-type-importing-applying-RGB-to-Dimensions-Measures/m-p/1592097#M43508</link>
    <description>&lt;P&gt;Good afternoon!&amp;nbsp;&lt;/P&gt;&lt;P&gt;I can find plenty of material for QlikView, but scant documentation for Qlik Sense, particularly surrounding usage of RGB colour to mix within charts / tables.&lt;/P&gt;&lt;P&gt;Until now, I've usually brought in the individual components of a particular colour of a dimension as R G B .&lt;/P&gt;&lt;P&gt;Having just discovered mapping as a more efficient way of renaming fields/data , in lieu of multiple joins,I'd thought it'd be possible to create an RGB field for mapping colour to dimension, to be mixed on measures.&lt;/P&gt;&lt;P&gt;I can load the data in and read the field value, however applying the colour value to either a table or visualisation returns an error if applied as an aggregate ( average / min etc. ) or simply an invisible / non-coloured element if applied directly.&lt;/P&gt;&lt;P&gt;The advantages of using applymapping&amp;nbsp; to re-use the same colour table might be outweighed by qliksense being unable to interpret the newly created field as a colour at all.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I'm using an inline table, with a numeric lookup , and a 3 dimensional vector for RGB.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;[RPT_CLR]:&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;Mapping&lt;/P&gt;&lt;P&gt;Load LUV_ID,RGB(X,Y,Z) AS CLR_BLEND Inline [&lt;BR /&gt;'LUV_ID','X','Y','Z',&lt;BR /&gt;-1,47,117,181,&lt;BR /&gt;0,99, 190, 123,&lt;BR /&gt;1,138, 201, 125,&lt;BR /&gt;2,177, 212, 127,&lt;BR /&gt;3,216, 223, 129,&lt;BR /&gt;4,255, 235, 132,&lt;BR /&gt;5,254, 203, 126,&lt;BR /&gt;6,252, 170, 120,&lt;BR /&gt;7,250, 138, 114,&lt;BR /&gt;8,248, 105, 107&lt;BR /&gt;];&lt;/P&gt;&lt;P&gt;Which is then applied like so:&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;MAP_LUV :&lt;/P&gt;&lt;P&gt;LOAD&lt;BR /&gt;PORTFOLIO_ID,&lt;BR /&gt;DUAL(ApplyMap('TEMP_LUV_MAP_FLAGGING',BEAN_BRACKET),BEAN_BRACKET) AS 'FILTER_BEAN_BRACKET',&lt;BR /&gt;DUAL(ApplyMap('RPT_CLR',BEAN_BRACKET),BEAN_BRACKET) AS 'COLOUR_BEAN_BRACKET'&lt;/P&gt;&lt;P&gt;RESIDENT PRICE_OF_BEANS;&lt;/P&gt;&lt;P&gt;;&lt;/P&gt;&lt;P&gt;Should I create an inline table for each color ( R G B ) and map them individually?&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I&lt;/P&gt;</description>
    <pubDate>Sat, 16 Nov 2024 20:40:00 GMT</pubDate>
    <dc:creator>johnnymartinez</dc:creator>
    <dc:date>2024-11-16T20:40:00Z</dc:date>
    <item>
      <title>RGB as a data type - importing /  applying RGB to Dimensions /  Measures</title>
      <link>https://community.qlik.com/t5/App-Development/RGB-as-a-data-type-importing-applying-RGB-to-Dimensions-Measures/m-p/1592097#M43508</link>
      <description>&lt;P&gt;Good afternoon!&amp;nbsp;&lt;/P&gt;&lt;P&gt;I can find plenty of material for QlikView, but scant documentation for Qlik Sense, particularly surrounding usage of RGB colour to mix within charts / tables.&lt;/P&gt;&lt;P&gt;Until now, I've usually brought in the individual components of a particular colour of a dimension as R G B .&lt;/P&gt;&lt;P&gt;Having just discovered mapping as a more efficient way of renaming fields/data , in lieu of multiple joins,I'd thought it'd be possible to create an RGB field for mapping colour to dimension, to be mixed on measures.&lt;/P&gt;&lt;P&gt;I can load the data in and read the field value, however applying the colour value to either a table or visualisation returns an error if applied as an aggregate ( average / min etc. ) or simply an invisible / non-coloured element if applied directly.&lt;/P&gt;&lt;P&gt;The advantages of using applymapping&amp;nbsp; to re-use the same colour table might be outweighed by qliksense being unable to interpret the newly created field as a colour at all.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I'm using an inline table, with a numeric lookup , and a 3 dimensional vector for RGB.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;[RPT_CLR]:&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;Mapping&lt;/P&gt;&lt;P&gt;Load LUV_ID,RGB(X,Y,Z) AS CLR_BLEND Inline [&lt;BR /&gt;'LUV_ID','X','Y','Z',&lt;BR /&gt;-1,47,117,181,&lt;BR /&gt;0,99, 190, 123,&lt;BR /&gt;1,138, 201, 125,&lt;BR /&gt;2,177, 212, 127,&lt;BR /&gt;3,216, 223, 129,&lt;BR /&gt;4,255, 235, 132,&lt;BR /&gt;5,254, 203, 126,&lt;BR /&gt;6,252, 170, 120,&lt;BR /&gt;7,250, 138, 114,&lt;BR /&gt;8,248, 105, 107&lt;BR /&gt;];&lt;/P&gt;&lt;P&gt;Which is then applied like so:&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;MAP_LUV :&lt;/P&gt;&lt;P&gt;LOAD&lt;BR /&gt;PORTFOLIO_ID,&lt;BR /&gt;DUAL(ApplyMap('TEMP_LUV_MAP_FLAGGING',BEAN_BRACKET),BEAN_BRACKET) AS 'FILTER_BEAN_BRACKET',&lt;BR /&gt;DUAL(ApplyMap('RPT_CLR',BEAN_BRACKET),BEAN_BRACKET) AS 'COLOUR_BEAN_BRACKET'&lt;/P&gt;&lt;P&gt;RESIDENT PRICE_OF_BEANS;&lt;/P&gt;&lt;P&gt;;&lt;/P&gt;&lt;P&gt;Should I create an inline table for each color ( R G B ) and map them individually?&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I&lt;/P&gt;</description>
      <pubDate>Sat, 16 Nov 2024 20:40:00 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/RGB-as-a-data-type-importing-applying-RGB-to-Dimensions-Measures/m-p/1592097#M43508</guid>
      <dc:creator>johnnymartinez</dc:creator>
      <dc:date>2024-11-16T20:40:00Z</dc:date>
    </item>
  </channel>
</rss>

