Qlik Community

QlikView Layout & Visualizations

Discussion Board for collaboration on QlikView Layout & Visualizations.

Not applicable

Change text format of values only for data points

I have a stacked bar chart with 3 decimal values. They all add upto 100. I am displaying these values on the bar as data points. But I don't want to show the decimal portion of these values, so I created an expression to Round these values. But when I do that, sometimes the total exceeds 100. How can I change the data point display to the rounded values, but use the actual value while calculating the height(total) of the bar?

1 Solution

Accepted Solutions
MVP
MVP

Re: Change text format of values only for data points


Hi,

You can set this by using

Chart Properties -> Number -> Select Expression and Set Integer

If it not working then upload the data that you are working.

Sometimes while rounding off your numbers may exceed 100, because 0.55 is rounded to 1, may be because of this the total may exceed 100.

Hope this helps you.

Regards,

Jagan.

8 Replies
MVP
MVP

Re: Change text format of values only for data points


Hi,

You can set this by using

Chart Properties -> Number -> Select Expression and Set Integer

If it not working then upload the data that you are working.

Sometimes while rounding off your numbers may exceed 100, because 0.55 is rounded to 1, may be because of this the total may exceed 100.

Hope this helps you.

Regards,

Jagan.

Not applicable

Re: Change text format of values only for data points

That setting rounds off the number as well. I have these values

4.9458000    85.9261000    9.1280000   

82.5788000    8.5442000    8.8771000   

These round off to

5     86     9     = 100

83     9     9     = 101

Because of this, the chart's bars are not of the same height. But they should be. I want to use the full decimal value in the calculation of that bar height.

Not applicable

Re: Change text format of values only for data points

Can you upload an example ?,

Employee
Employee

Re: Re: Change text format of values only for data points

I am not experiencing the same issue with my little sample.  Can you please post what you are seeing.

Not applicable

Re: Change text format of values only for data points

This is my generated chart.

Capture.PNG.png

Not applicable

Re: Change text format of values only for data points

Hope this helps i just used teh Round out of the Sum , and the texts had the round inside ,,

REPOST ....

HERE YOU GOT AN EXAMPLE, HOPE THIS HELPS

Regards!!

Employee
Employee

Re: Change text format of values only for data points

This is correct.   Everything is rounding correctly.  The fact that when you add up the numbers being displayed you do not get exact numbers is what happens when you round.  Are you suggesting that the bottom bar should display 9,9 and 82?  That would be mathematically incorrect and misleading.  If you need more precision in your results then add decimal places.

Not applicable

Re: Change text format of values only for data points

Thanks everyone. I hasn't removed the Round function from the expressions. Thats why even after fixing the Number presentation, I was seeing the wrong height.

Community Browser