Forum Discussion
Anonymous
6 years agoNot applicable
Vertical lines in a graph
Hello, I have several line charts in a report where date in on the x-axis like this Is there a smart way to draw vertical lines on certain days, like when a certain marketing campaign s...
- 6 years ago
Hi,
According to your description, i think your requirement can not be reached completely, but i have a workaround:
Please choose Line and Clustered Column Chart visual.
Then try this measure:
Measure = IF ( DISTINCTCOUNT ( 'Slicer Table'[Date] ) = BLANK () || DISTINCTCOUNT ( 'Slicer Table'[Date] ) = CALCULATE ( DISTINCTCOUNT ( 'Slicer Table'[Date] ), ALL ( 'Slicer Table' ) ), BLANK (), IF ( MIN ( 'Table'[Date] ) IN DISTINCT ( 'Slicer Table'[Date] ), MAXX ( CALCULATETABLE ( DISTINCT ( 'Table'[Date] ), ALLSELECTED ( 'Table'[Date] ) ), CALCULATE ( SUM ( 'Table'[Sales] ) ) ) ) )Create another seperate slicer table:
Slicer Table = SELECTCOLUMNS('Table',"Date",'Table'[Date])When choose one or more dates you want in slicer, the result shows:
You can also use another custom visual called Multiple Axes Chart - XViz :
The result shows:
Here is my test pbix file:
Hope this helps.
Best Regards,
Giotto Zhi
amitchandak
6 years agoSuper User
I think you need use line and stacked chart and have a measure on Bar that have filter of campaign