Forum Discussion
annaharris
1 year agoRegular Visitor
Combining Two Data Matrices into One
Hi Everyone, I am currently working on a project where I need to create a single matrix that displays data categorised by various metrics. I have successfully created two separate matrices but am...
shafiz_p
1 year agoSuper User
Hi annaharris It is hard provide exact solution with such few details. It is better to provide representative data and your desired output.
However, You could try the below codes to achieve this:
This mesure will only respond with the slicer selection:
SelectedCentreMetric =
CALCULATE(
[Measure],
FILTER(
'Table',
'Table'[Centre] = SELECTEDVALUE('Table'[Centre])
)
)
This measure will work for all location type either Metro or Non-Metro.
MetroNonMetroMetric =
CALCULATE(
[Measure],
FILTER(
'Table',
'Table'[LocationType] IN {"Metro", "Non-Metro"}
)
)
Hope this helps!!
If this solved your problem, please accept it as a solution and a kudos!!
Best Regards,
Shahariar Hafiz
- annaharris1 year agoRegular Visitor
I had a go with the code you provided but I can't use calculated fields as a Column in the matrix visual. Not sure if I'll need to create a new table as a source and link it to that?
I'm quite new to PowerBI so I'm still wrapping my head around the moving parts.