Forum Discussion
Todward
6 years agoFrequent Visitor
Line Chart with YTD average figures
Dear all I would like to create a line chart similar to the one in the screenshot below. However the figures in this chart should not be the monthly figures but the YTD average of this specific m...
- 6 years ago
Hey @Todward ,
I guess you have a dedicated calendar table, which is related to your fact table. I also recommend reading this article: https://www.daxpatterns.com/time-patterns/
I create two measures for its volume and COGS as well:
YTD quantity = TOTALYTD(CALCULATE(SUM('Fact Sale'[Quantity])) , 'Dimension Date'[Date])Create a third measure that divides the previous measures accordingly.
Hopefully, this provides what you're looking for.
Best regards
cat
TomMartens
6 years agoSuper User
Hey @Todward ,
I guess you have a dedicated calendar table, which is related to your fact table. I also recommend reading this article: https://www.daxpatterns.com/time-patterns/
I create two measures for its volume and COGS as well:
YTD quantity = TOTALYTD(CALCULATE(SUM('Fact Sale'[Quantity])) , 'Dimension Date'[Date])
Create a third measure that divides the previous measures accordingly.
Hopefully, this provides what you're looking for.
Best regards
cat
- Todward6 years agoFrequent Visitor