Forum Discussion
Filter Matrix for 1 column
- 4 years ago
Hi shermayne123 ,
This is my test table:
Please try following measure to create a new column:
Percentage = var _count = CALCULATE(COUNT('Table'[Reclassified Responses]),FILTER('Table','Table'[Question]=EARLIER('Table'[Question]) && 'Table'[Reclassified Responses] = EARLIER('Table'[Reclassified Responses]))) var _allcount = COUNTX(FILTER('Table','Table'[Question] = EARLIER('Table'[Question])),'Table'[Reclassified Responses]) return DIVIDE(_count,_allcount)Create a matrix visual:
After filtering:
Please refer the attached pbix file.
Best regards,
Yadong Fang
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
shermayne123 , use all in the denominator measure
example
divide([m1], calculate([m2], all(Table[Question])) )
If this does not help
Can you share sample data and sample output in table format? Or a sample pbix after removing sensitive data.
- shermayne1234 years ago
Helper I
Hi amitchandak,
Don't quite know how to adjust the vizualization using your line of code. Can you kindly enlighten?
Below are the screenshots of my data table :
And the sample output desired i.e. the matrix visualization with the desired percentages:
Hope that clarifies. Please let me know if otherwise, thank you!