Forum Discussion
Add constant lines to small multiples
- 10 months ago
Hi HANA7B ,
You cannot add dynamic constant lines directly with smal multiples you can however make error bar that can match this.
Try the following steps:
- Select a column and line chart
- Create the following measure:
Constant = SWITCH(TRUE(), SELECTEDVALUE( Products[Class]) = "H" && SELECTEDVALUE('Calendar'[day]) = 20, 1, SELECTEDVALUE( Products[Class]) = "L" && SELECTEDVALUE('Calendar'[day]) = 15, 1, SELECTEDVALUE( Products[Class]) = "M" && SELECTEDVALUE('Calendar'[day]) = 10, 1) Upper = CALCULATE([Total Quantity], REMOVEFILTERS('Calendar'[day])) Lower = 0In my case the Product[Class] is the column I'm using on the small multiples and the Total Quantity is the column I'm using in my visual
- Setup of visual:
- X-Axis: Day
- Column Y-Axis: Total Quantity
- Line Y-Axis: Constant
- Small Multiples Class
- Error Bars:
- By Field
- Upper Bound: Upper measure
- Lower Bound Lower measure
- Relationship to measure: Absolute
- Bar: on
- Color selet to you needs
- Turn of lines so that the marker does no show
- Turn off values in secondary axis
Final Result:
Hi HANA7B ,
Thank you for reaching out to the Microsoft Community Forum.
Hi MFelix , Thank you for your prompt response.
Hi HANA7B , Could you please try the proposed solution shared by MFelix ? Let us know if you’re still facing the same issue we’ll be happy to assist you further.
Regards,
Dinesh
- v-dineshya10 months agoCommunity Support
Hi HANA7B ,
We haven’t heard from you on the last response and was just checking back to see if you have a resolution yet. And, if you have any further query do let us know.
Regards,
Dinesh
- v-dineshya10 months agoCommunity Support
Hi @HANA7B ,
We haven’t heard from you on the last response and was just checking back to see if you have a resolution yet. And, if you have any further query do let us know.
Regards,
Dinesh