Skip to main content
Announcements
Join us at Qlik Connect for 3 magical days of learning, networking,and inspiration! REGISTER TODAY and save!
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Bar Chart: Expression label inside the bar

Hi all,

I'm facing an issue.

- I've a bar chart that i'll turn into a waterfall using a bar offset for each expression

- This bar char is composed of 5 expressions.

I would like to have in each bar the label of the expression.

Any Idea?

1 Solution

Accepted Solutions
Not applicable
Author

Based on Gysbert answer,

Dual('MyLabel' & chr(10) & num(MyExpression, '0.0%'), MyExpression)

I have now both Expression Name and it's value by the top of the bar.

Many Thanks.

View solution in original post

6 Replies
alexandros17
Partner - Champion III
Partner - Champion III

The only way is (if you have a fixed number of bars) go to tab "Presentation" and in "text in chart" you can add text (even vertically)

hope it helps

Gysbert_Wassenaar

Use the dual function: dual('MyLabel', myexpression). Replace MyLabel with the label of the expression and myexpression with the expression itself. The bar will use the text MyLabel to display in the bar and the value of myexpression for the length of the bar.


talk is cheap, supply exceeds demand
Not applicable
Author

go to properties of bar chart

clik on  Number tab

select Expression Default value

then write in symbol = test

then test as a label for expression.

see the attachement.

Not applicable
Author

Based on Gysbert answer,

Dual('MyLabel' & chr(10) & num(MyExpression, '0.0%'), MyExpression)

I have now both Expression Name and it's value by the top of the bar.

Many Thanks.

Not applicable
Author

Hi, my current chart expression is using :     =$(vTotalCompliance)  which is a %'age rate.

My Label is Unit

If I try to use  Dual(Unit,$(vTotalCompliance)) the label is not appearing within each bar segment.

Do  you have any suggestions?

Many thanks for your time

wagnepat
Contributor
Contributor

Hi Gysbert,

I tried your function but somehow it doesn't work (below you see the expression and the dual function (dark blue = expressen, lightblue = dual function)).

Do you have any idea what I can that it works?

QV-label-in-barchart.png

Thank you,

Patrick