Power BI is turning 10! Tune in for a special live episode on July 24 with behind-the-scenes stories, product evolution highlights, and a sneak peek at what’s in store for the future.
Save the dateEnhance your career with this limited time 50% discount on Fabric and Power BI exams. Ends August 31st. Request your voucher.
Hi
I am looking to find at what the increase in value is (and percentage) to the previous date in my date column.
I would class it as a week on week difference - however, i only have the Monday date each week available.
Is this possible? The table below is some example data - i am trying to achieve the outcomes withi the 'Week on Week Difference' column and the & Difference column
Thank you in advanced
Date | Value | Week on Week Difference | % Difference |
27/02/2023 | 49246997 | ||
06/03/2023 | 48361947 | -885050 | -1.8% |
13/03/2023 | 37187599 | -11174348 | -23.11% |
20/03/2023 | 45926791 | 8739192 | 23.5% |
27/03/2023 | 45581085 | -345706 | -0.75% |
Hi @browna6 ,
Could you please try the following measure for the week over week difference?
Week on Week Difference =
VAR prevValue =
CALCULATE(
SUM( Table[Value] ),
OFFSET(
-1,
ORDERBY( Table[Date] , ASC )
)
)
RETURN
IF(
NOT( ISBLANK( prevValue ) ),
CALCULATE(
SUM( Table[Value] ) - prevValue
)
)
Do not forget to replace "Table" with the correct name of your table. For the percentage, I wrote the following but do not find the same result as you (except for first and last value). Could you explain your calculation?
Difference % =
CALCULATE(
DIVIDE(
[Difference],
SUM( Table[Value] )
)
)
Thanks,
If my solution is correct, please mark it as a solution to help people with the same question as you in the future.
User | Count |
---|---|
25 | |
12 | |
8 | |
6 | |
6 |
User | Count |
---|---|
26 | |
12 | |
11 | |
9 | |
6 |