Skip to main content
Announcements
See why Qlik is a Leader in the 2024 Gartner® Magic Quadrant™ for Analytics & BI Platforms. Download Now
cancel
Showing results for 
Search instead for 
Did you mean: 
asamariaekrickl
Partner - Contributor III
Partner - Contributor III

Bar chart too wide gap

Hi there,

I have created a bar chart with FinancialYear as the dimension and two expressions showing current year and previous year.

The problem is the big gap between the bars and that the bars are at each side of the chart.

Do you have any idea what might cause this gap?

Bar chart.PNG

Labels (1)
7 Replies
ramasaisaksoft

Hi,

 

 we can custom bar distance by options like bar distance.PNG

asamariaekrickl
Partner - Contributor III
Partner - Contributor III
Author

Thanks, but I have tried all those without success.

 

Asa

jonathandienst
Partner - Champion III
Partner - Champion III

This looks like two bars per year, with the 'wrong' year evaluating to zero, so there are two zero bars in the middle. If you provide more information (or preferably a small sample qvw illustrating the problem), then you will get suggestions on how to remove the extra zero bars.

Logic will get you from a to b. Imagination will take you everywhere. - A Einstein
asamariaekrickl
Partner - Contributor III
Partner - Contributor III
Author

Hi,

I'm sorry I can't share a sample qvw unfortunately.

There are two expression:

Expression 1
avg({<[Performance Indicators / Measures]=, YTD=, QTDLQ=, MTDLM=, FinancialYear=,[FY Year Number] = {'$(=$(vMaxFYYear-1))'}>} [KPI Value])

Expression 2
avg({<[FY Year Number] = {'$(=$(vMaxFYYear))'}>} [KPI Value])

Variables
max(right(FinancialYear,2)-1)
and
max(right(FinancialYear,2))

FY Year Number is 

Capture.PNG

If you have any ideas how to remove these extra bars, that would be amazing.

 

Asa

anushree1
Specialist II
Specialist II

Can you Try creating the same chart using straight table that would help us check if there are any years in between with 0 or 0.000789 kind of values and then treat the situation accordingly

asamariaekrickl
Partner - Contributor III
Partner - Contributor III
Author

No clues there I'm afraid

Capture.PNG

A clue though is that this is gap is happening in all charts in this app. And there are a few... 🙂

anushree1
Specialist II
Specialist II

the issue here is that 2 expressions are used and one of them is null whereas the other has value thus an empty placeholder for the Null expression gets created, try using a single expression and that will help you understand the cause better