Skip to main content
Announcements
Qlik Introduces a New Era of Visualization! READ ALL ABOUT IT
cancel
Showing results for 
Search instead for 
Did you mean: 
Amit_B
Creator
Creator

Set color to measure

Hi,

How can I set color to measure?

I am using a bar chart, I want all the bars that shows the actual cost display in one color (for example, green instead of blue) and the bars that shows the budget display in another color. It's like what's happening by default, but I want to change the colors.

I tried to change the colors in the master items but it does not affect the object.

IMG-20240225-WA0001.jpg

Thanks!

(QS November 2023)

Labels (2)
5 Replies
PhanThanhSon
Creator II
Creator II

Hi,

I assume you only use one master element when you're dealing with a single master element indicator. In such cases, adjustments must be made through the chart settings, as shown in the figure.

PhanThanhSon_0-1708862459499.png

 

However, if you're dealing with two indicators, you can incorporate them directly into the master indicators.

I've used the following demo dataset:

 

DemoData:
Load * Inline [
Year, FLAG, Measure
2023, Actual, 500
2023, Budget, 1000
2024, Actual, 500
2024, Budget, 700 ];

Best regards Son

Amit_B
Creator
Creator
Author

Thanks for your answer.

Unfortunately I can't do it. I wrote a simple example, my real data is much more complex than that.

It's like I have to change the colors in the theme.

stevedark
Partner Ambassador/MVP
Partner Ambassador/MVP

Hi @Amit_B 

The segment values you are changing there refer to colours based on the result of the measure.

There is a separate colour selection on the main details for the measure:

stevedark_0-1708896070329.png

You can pick a different colour for each measure and this is the default colour used whenever that measure is used.

stevedark_1-1708896144263.png

Hope that this delivers what you are after?

I wouldn't recommend using the colours I have selected though!

Cheers,
Steve

 

Amit_B
Creator
Creator
Author

Thanks, don't know how I missed it.

In any case, I understand that this does not give me a good solution.

It changed the colors in every object I use this master item, I wanted to change several objects.

In addition, in some objects I made a calculation with this master item, for example to divide by 1000 and use K in the format. So, in these objects it didn't change but i need to change them.

I guess I'll must try to build a new theme..

stevedark
Partner Ambassador/MVP
Partner Ambassador/MVP

Hi @Amit_B 

To deal with the /1000, you could duplicate the master measure, divide by 1000 in the duplicate master measure and then set that to the same colour as the measure it was cloned from.

However, if you do go for modifying the theme instead, then I recommend starting from here:
https://sensetheme.com/

Thanks to @barryharmsen and his team for putting that site together.

Cheers,
Steve