Forum Discussion
Anonymous
2 years agoNot applicable
DAX Calculation - Scaling Value based on Sum(Value) in same Column
Hi, I have a dataset containing cars with several measurements (example: number of honks). The honks are measured at different times and then summed. I now want to scale the number of honks depen...
Anonymous
2 years agoNot applicable
Hi Anonymous ,
Could not access the sample data that you share, i create a sample for you with my understand.
Please try below steps:
1. below is my test table
Table:
2. create a measure with below dax formula
Measure =
VAR _a =
SELECTEDVALUE ( 'Table'[Car Name] )
VAR tmp1 =
FILTER ( ALL ( 'Table' ), [Car Name] = _a )
VAR tmp2 =
SELECTCOLUMNS ( tmp1, "Honks", [Honks] )
VAR tmp3 =
SELECTCOLUMNS ( tmp1, "KMS", [KMS] )
VAR _b =
SUMX ( tmp2, [Honks] )
VAR _c =
SUMX ( tmp3, [KMS] )
RETURN
DIVIDE ( _b, _c ) * 100
3. add a table visual with table fields and measure
Please refer the attached .pbix file.
Best regards,
Community Support Team_Binbin Yu
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.