Skip to main content
Announcements
July 15, NEW Customer Portal: Initial launch will improve how you submit Support Cases. IMPORTANT DETAILS
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Changing bar colour when using a calculated dimension

Hi guys,

I've created a bar chart using a calculated dimension (which has 6, custom-made bars).

I want to change the colour of SOME of these bars, and not others. How do I do this?

For instance, I'd like

Calculated Bar 1 - Red

Calculated Bar 1 - Blue

Calculated Bar 1 - Blue

Calculated Bar 1 - Red

Thanks!

7 Replies
Not applicable
Author

Hi O G,

do you have 6 expressions in this chart?

regards

Darek

Not applicable
Author

Hi,

I have one expression, which is simply a count of the variable I have sorted based on the custom dimension.

As an example, the custom dimension seperates values in to groups of values, i.e. 1-50, 51-100, 101-200 etc.

Not applicable
Author

Hello,

find my example.

You can use conditional expression in backgroud color (under your expression).

regards

Darek

Not applicable
Author

Hi Dariusz,

Thanks for your responce, however this does not seem to be working.

I'm grouping the dimension as discussed above, so the dataset looks something like this:

1

20

38

19

2

39

49

28

etc...

Then i'm grouping these using a calculated dimension to 1-50, 51-100, 101-200 categories, and THEN counting how many of each there are, so the bar chart has the three categories above, with a count for each as the expression.

I want to be able to change the colour of the '1-50' only.

Any ideas? Unable to post a QVW as working with sensitive data. Thanks.

Not applicable
Author

Get color expression from my example and change condition. It should work. If not - prepare qvd with few rows or you may scramble your sensitive data.

regards

Darek

jsingh71
Partner - Specialist
Partner - Specialist

Share your sample qvw file.

maleksafa
Specialist
Specialist

in your dimension tab, under used dimensions, you can expand the dimension that you want and then go to background color and there you can use the built in color functions or use the RGB function to put your color.