Forum Discussion
Anonymous
4 years agoNot applicable
Aggregate Month End Percentages
Say I have the following table: Measure A Measure B Month 5 10 Jan 3 30 Jan 6 ...
- 4 years ago
Hi,
I assume measure A and measure B are columns.
Please check the below picture and the attached pbix file.
Expected result measure: = VAR _newtable = ADDCOLUMNS ( VALUES ( Data[Month] ), "@sumcolumnA", CALCULATE ( SUM ( Data[Measure A] ) ), "@sumcolumnB", CALCULATE ( SUM ( Data[Measure B] ) ) ) RETURN AVERAGEX ( _newtable, [@sumcolumnA] / [@sumcolumnB] ) * 100
Jihwan_Kim
Super User
4 years agoHi,
I assume measure A and measure B are columns.
Please check the below picture and the attached pbix file.
Expected result measure: =
VAR _newtable =
ADDCOLUMNS (
VALUES ( Data[Month] ),
"@sumcolumnA", CALCULATE ( SUM ( Data[Measure A] ) ),
"@sumcolumnB", CALCULATE ( SUM ( Data[Measure B] ) )
)
RETURN
AVERAGEX ( _newtable, [@sumcolumnA] / [@sumcolumnB] ) * 100