The ultimate Fabric, Power BI, SQL, and AI community-led learning event. Save €200 with code FABCOMM.
Get registeredCompete to become Power BI Data Viz World Champion! First round ends August 18th. Get started.
Hi All,
Kindly suggest how to exclude showing zero values in line graph
Note: as line graph has calculated values when i use filter other measures get cutdown to period 09.
Solved! Go to Solution.
Hi @Snagalapur
To exclude zero values from your line graph without affecting other measures or periods, you can modify your measure to return BLANK() when the value is zero. In Power BI, data points with BLANK() values are not plotted in line charts, effectively removing them from the visual.
Here's how you can do it:
Modify Your Measure:
Adjust the measure used in your line graph to return BLANK() when the result is zero. For example:
Adjusted Measure =
IF([Your Original Measure] = 0, BLANK(), [Your Original Measure])
Replace [Your Original Measure] with the actual measure you're using in the line graph.
Use the Adjusted Measure in Your Line Graph:
Replace the existing measure in your line graph with the new Adjusted Measure.
This will display all your data as before but will exclude the zero values from the line graph.
If this post helps, please consider accepting it as the solution to help the other members find it more quickly.
Appreciate your Kudos!!
LinkedIn|Twitter|Blog |YouTube
Thanks for the replies from Rupak_bi and VahidDM.
Hi @Snagalapur ,
I'll add one more detail here: If, after making changes to the measure, some data points are missing from the x-axis, you can select the X-axis field and click "Show item with no data".
Best Regards,
Zhu
If there is any post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Hi @Snagalapur
To exclude zero values from your line graph without affecting other measures or periods, you can modify your measure to return BLANK() when the value is zero. In Power BI, data points with BLANK() values are not plotted in line charts, effectively removing them from the visual.
Here's how you can do it:
Modify Your Measure:
Adjust the measure used in your line graph to return BLANK() when the result is zero. For example:
Adjusted Measure =
IF([Your Original Measure] = 0, BLANK(), [Your Original Measure])
Replace [Your Original Measure] with the actual measure you're using in the line graph.
Use the Adjusted Measure in Your Line Graph:
Replace the existing measure in your line graph with the new Adjusted Measure.
This will display all your data as before but will exclude the zero values from the line graph.
If this post helps, please consider accepting it as the solution to help the other members find it more quickly.
Appreciate your Kudos!!
LinkedIn|Twitter|Blog |YouTube
Thank you for help.
Hi @Snagalapur ,
If the values are coming from column, put filter of those in the filter pane. J
If values are coming from a measure,
Put an if logic in the measure
If ( max( table,value)= 0, blank(), the original
User | Count |
---|---|
83 | |
83 | |
37 | |
34 | |
32 |
User | Count |
---|---|
92 | |
79 | |
61 | |
51 | |
51 |