Forum Discussion
Table with values switch to rows, difference, impact columns
- 1 year ago
Hi Evelin_ - you can create the Difference (pp) measure
Difference_pp =
VAR CY = [CY selection]
VAR Base = [Base selection]
RETURN
FORMAT(CY - Base, "0.0") & " pp"you want the impact to be a function of the pp difference and some weighting
Impact =
VAR pp = [CY selection] - [Base selection]
-- You can apply a custom logic here
-- e.g., multiply by a fixed factor, or lookup a weight from a table
RETURN
pp * [SomeWeight] -- Or a hardcoded number like 200If the weight is fixed or based on the row context
Impact =
VAR pp = [CY selection] - [Base selection]
VAR impactFactor =
SWITCH(
SELECTEDVALUE('MetricsTable'[Metric]),
"Total", 200,
"Promo", 100,
"xx", 10,
0
)
RETURN
pp * impactFactorHope this helps.
Hi Evelin_ - you can create the Difference (pp) measure
Difference_pp =
VAR CY = [CY selection]
VAR Base = [Base selection]
RETURN
FORMAT(CY - Base, "0.0") & " pp"
you want the impact to be a function of the pp difference and some weighting
Impact =
VAR pp = [CY selection] - [Base selection]
-- You can apply a custom logic here
-- e.g., multiply by a fixed factor, or lookup a weight from a table
RETURN
pp * [SomeWeight] -- Or a hardcoded number like 200
If the weight is fixed or based on the row context
Impact =
VAR pp = [CY selection] - [Base selection]
VAR impactFactor =
SWITCH(
SELECTEDVALUE('MetricsTable'[Metric]),
"Total", 200,
"Promo", 100,
"xx", 10,
0
)
RETURN
pp * impactFactor
Hope this helps.