Forum Discussion
ItsPS
2 years agoNew Member
Calculating Contribution to Change for a dataset
Hi All, I'm trying to calculate the Cont to Chage column in PowerBI Dax but struggling to do so : We have to Sum of Diff column based on following logic: 1. When LEVEL 3, LEVEL 4 and LEVEL 5 ...
Elcin_7
Helper I
2 years agoHi, Question is not that clear there is no level 5 in the table. But I will explain how I would approch as far as I understood. I would create a conditional coloumn in power query and I would say if level 2 and level 3 and level 4 is "null" tell "emthy" and else "data". And I would create a DAX formula depending this logic.
Difference TY PY =
IF(
SELECTEDVALUE('Sheet1'[Custom]) = "Emthy",
SUM('Sheet1'[Value TY]) - SUM('Sheet1'[Value PY]),
0
)
With similar logic if the new calculated colum is "emthy" and you can show cont to change as %100 with If formula or else you can create your calculation.