Forum Discussion
wbhite
Helper I
6 years agoNeed help understanding how this visual works
Hi all, I'm trying to create a simple bar chart and can't understand why it's condensing the bars, as shown below. Thanks!
mwimberger
Resolver II
6 years agoHi wbhite
This squishing of the bars together is due to the measure that is creating the bars giving a result that is zero for some periods on the x axis. One approach is to use a conditional if statement that sets the measure result to blank() if the result is zero. I presume your x axis is a date axis ? So what is happening is all periods in your (selected) date period are plotting even if there are zeros.
You can also on the visual controls choose not to plot this and choose only plot points with data.
I’ll draw up an example for you shortly
Cheers
Manfred
This squishing of the bars together is due to the measure that is creating the bars giving a result that is zero for some periods on the x axis. One approach is to use a conditional if statement that sets the measure result to blank() if the result is zero. I presume your x axis is a date axis ? So what is happening is all periods in your (selected) date period are plotting even if there are zeros.
You can also on the visual controls choose not to plot this and choose only plot points with data.
I’ll draw up an example for you shortly
Cheers
Manfred
- mwimberger6 years ago
Resolver II
Hi
Ok, first things first : make sure that the axis ( or shared axis for a composite line / bar graph ) does not have the "Show Items with no data " ticked.
Then if this doesn't solve it fully, adjust your measure with an if statement to set items that are blank or zero to blank
Measure_Test = IF ( ISBLANK ( Calculation_you_want ), BLANK (), calculation_you_want )Let me know if you come right
Cheers
Manfred