Forum Discussion
Anonymous
7 years agoNot applicable
Creating Table / Matrix with Measures in Rows and different time periods in columns
I am moving from Tableau to powerBI and i am looking to recreate reate the following visual / matrix / table. But I am struggeling. In general, is a structure like this possible in a PowerBI report? ...
Arnault_
7 years agoResolver III
Anonymous,
You can do that in Power BI. You will have to create a measure for each expected outputs:
Last n days =
CALCULATE (
SUM ( Table[val] ),
FILTER (
ALL ( Table ),
Table[date]
>= MAX ( Table[date] ) - n
&& Table[date] <= MAX ( Table[date] )
)
)
Then, check MTD and YTD function, many examples can be found on the forum.
Same for LY using SAMEPERIODLASTYEAR function.
Please aslo check microsoft documentation which provide examples :
https://docs.microsoft.com/en-us/dax/sameperiodlastyear-function-dax
Cheers