Forum Discussion
Data label for min & max values plus current month only for month & quarter views
- 10 months ago
Hii icassiem
You can’t reliably merge min, max, and current period into a single measure and still get multiple data labels. Power BI renders one label per measure per data point, so a single “combined” measure would only ever show one label. The helper-measure approach is the correct and supported pattern. To reduce clutter, you can turn off legend, rename measures with a blank character, or remove them from tooltips, but they must remain separate measures. The logic will still work across month/quarter/year as long as the axis comes from the Date table and you use ISINSCOPE if needed.
Hii icassiem
You can implement this by using helper measures that return a value only at the required point and BLANK() elsewhere. For example, assuming [Actual] is your base measure:
Actual Current Period :=
IF (
MAX ( 'Date'[Date] ) = MAXX ( ALLSELECTED ( 'Date' ), 'Date'[Date] ),
[Actual]
)
Actual Min :=
IF (
[Actual]
= MINX ( ALLSELECTED ( 'Date' ), [Actual] ),
[Actual]
)Actual Max :=
IF (
[Actual]
= MAXX ( ALLSELECTED ( 'Date' ), [Actual] ),
[Actual]
)
Add these three measures to the same line chart and turn Data Labels = ON. Power BI will only render labels where the measure is not blank (min, max, and current month/quarter). If you switch between month and quarter, the logic still works as long as your axis comes from the Date table (you can refine it further with ISINSCOPE() if needed).
rohit1991thank you, i think i follow
so these will be additional lines to graph with its own data lables and not the key lines, and i cant use them in the key lines dta lables selection
- downside i guess, it adds to the tooltip and posisbly need to custom tootip and additional to legend which i cant confuse leader group team
can i not create a fouth measure, to merge the 3 measures with if blank then min else max else month for one measure as the key lines data label BUT would it still work for diff date grains (month, quarter, year)?
- icassiem10 months ago
Post Prodigy
rohit1991 , cengizhanarslan please any update my last reply?
- rohit199110 months ago
Super User
Hii icassiem
You can’t reliably merge min, max, and current period into a single measure and still get multiple data labels. Power BI renders one label per measure per data point, so a single “combined” measure would only ever show one label. The helper-measure approach is the correct and supported pattern. To reduce clutter, you can turn off legend, rename measures with a blank character, or remove them from tooltips, but they must remain separate measures. The logic will still work across month/quarter/year as long as the axis comes from the Date table and you use ISINSCOPE if needed.
- icassiem10 months ago
Post Prodigy
Thank you rohit1991 ; cengizhanarslan