Forum Discussion
madden318
9 years agoRegular Visitor
Line graph - Line continues for months with no data
Have an issue with a line chart showing multiple lines each representing a year. 2016 line continues even though there is no data for november and december. How can i get rid of this?
alanhodgson
9 years agoSolution Supplier
Hey madden318,
Easy fix, go to the paint roll "Format" tab and under the "X-Axis" dropdown, change the type to "Categorical" instead of "Continuous". This should stop the graph at the last point.
Hope this helps,
Alan
madden318
9 years agoRegular Visitor
Thanks Alan but it is already on the categorical setting. Has this ever fixed it for you?
- alanhodgson9 years agoSolution SupplierThat works for me. It looks like PBI is defaulting your data for 2016 in the last 2 months to zero. Does it do the same thing for other types of graphs or is it just the line graph?
- madden3189 years agoRegular Visitor
Yes it is definitley adding 0 values into may data where there is none. Tried switching it to a line and stacked volume chart and it did the same thing.
- v-ljerr-msft9 years agoMicrosoft Employee
Hi madden318,
You should be able to use BLANK Function (DAX) to skip the value 0 in this scenario. For example, if you are showing "Total Sales" on the Line Chart.
Total Sales = SUM ( Sales[Revenue] )
Then you should be able to show the following measure instead on the Line Chart to skip the value 0.
Measure = IF ( [Total Sales] = 0, BLANK (), [Total Sales] )
Regards