Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 
Anonymous
Not applicable

Highlight with colors instead of filtering the chart

Hi,

I would like to highlight columns in a column chart based on a selection you make from another table.

Example:

If I select KPI B in the table in the picture attached, I would like the right bar chart to highlight columns for 201806 and 201808 (as this is the corresponding YearMonths in the table) with a red color instead of filtering the chart.

The same way if you choose the comment in row 3 in the table, I would like the right bar chart to highlight column for 201808 (as this is the corresponding YearMonth in the table) with a red color instead of filtering the chart.

If nothing is selected in the table, the chart should be as it is in the picture.

This is fairly easy done in Tableau and Power BI, but how is it made in Qlik Sense?

I have also attached my dummy data as an Excel file and the application.

I hope you can help.

Br,

Thomas

1 Solution

Accepted Solutions
RicardodelaRosaQlik

Yeah, no problem. I forced it to do only on KPI B. Just a little change.


You can adjust the colors as you want. I used the default functions red() and blue().

Regards
Ricardo

View solution in original post

11 Replies
agigliotti
Partner - Champion
Partner - Champion

I guess you can't, what you asking for works only within the chart object where you make the selection.

OmarBenSalem

assume u have this measure in ur bar chart:

sum(YourMeasure)

this is how I would do it:

sum({<KpiID,KPI>}YourMeasure)

and color it by measure:

sum(YourMeasure)

In that case, when u select a KPI, all the bars would still be shown, but only the one associated to ur selection would be colored; thus highlited

Anonymous
Not applicable
Author

Hi,

Thanks for your answer, however I do not think it gives me what I want.

By coloring it by measure each bar has a different column.

What I want:

By default (nothing selected in the table) every columns in the bar chart should have the same color.

If I choose KPI B in the table, the columns for 201806 and 201808 in the right bar chart should change color (because KPI B has comments for YearMonth 201806 and 201808), whereas the other column should keep the original color.

Hope it makes sense...

OmarBenSalem

Can u share a sample application to directly work on?

Anonymous
Not applicable
Author

Yes, it is attached in the original post now.

RicardodelaRosaQlik

Hi,

look the attached qvf! Do you want something like that?

Regards!!
Ricardo

Anonymous
Not applicable
Author

Hi Ricardo,

Thank you!

It is almost like that, however is it possible to make it more dynamic. It should work the same way for the other KPI's, so if you fx. select KPI A it should color column 201804. But in the real dataset I have lots more KPI's, so is there another way instead of using nested IF's in the color expression?

Br,

Thomas

RicardodelaRosaQlik

Yeah, no problem. I forced it to do only on KPI B. Just a little change.


You can adjust the colors as you want. I used the default functions red() and blue().

Regards
Ricardo

Anonymous
Not applicable
Author

Ahh yes, thank you very much Ricardo!