Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Good afternoon!
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.
Until now, I've usually brought in the individual components of a particular colour of a dimension as R G B .
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.
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.
The advantages of using applymapping 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.
I'm using an inline table, with a numeric lookup , and a 3 dimensional vector for RGB.
[RPT_CLR]:
Mapping
Load LUV_ID,RGB(X,Y,Z) AS CLR_BLEND Inline [
'LUV_ID','X','Y','Z',
-1,47,117,181,
0,99, 190, 123,
1,138, 201, 125,
2,177, 212, 127,
3,216, 223, 129,
4,255, 235, 132,
5,254, 203, 126,
6,252, 170, 120,
7,250, 138, 114,
8,248, 105, 107
];
Which is then applied like so:
MAP_LUV :
LOAD
PORTFOLIO_ID,
DUAL(ApplyMap('TEMP_LUV_MAP_FLAGGING',BEAN_BRACKET),BEAN_BRACKET) AS 'FILTER_BEAN_BRACKET',
DUAL(ApplyMap('RPT_CLR',BEAN_BRACKET),BEAN_BRACKET) AS 'COLOUR_BEAN_BRACKET'
RESIDENT PRICE_OF_BEANS;
;
Should I create an inline table for each color ( R G B ) and map them individually?
I