Starting December 3, join live sessions with database experts and the Microsoft product team to learn just how easy it is to get started
Learn moreGet certified in Microsoft Fabric—for free! For a limited time, get a free DP-600 exam voucher to use by the end of 2024. Register now
I have a table that shows which questions on a test were answered correctly by student (No = incorrect, Yes = correct)
Student Question-A Question-B Question-C Question-D Question-E Question-F
Joe No Yes Yes Yes No Yes
Ian No Yes Yes Yes No Yes
Tia No No Yes Yes Yes Yes
What I would like to do is:
1) Calculate the top 3 questions with the most "No" answers and display them in a visual
2) Show the percentage of all "Nos" in the table that question accounts for
For example: the following questions would show up in my visual (multi row card perhaps), in order of highest "No" count
Question-A 17%
Question-E 11%
Question-B 6%
Any guidance is much appreciated!
Solved! Go to Solution.
Hi @Leeny127,
Please modify your data with Power Query by unpivoting all the anwer and keeping the student field.
Then load it in the power pivot model and you can use this formula where I called my table(Table1), and the 3 fields Student, Answer and Question:
Measure = var AnswerNo=CALCULATE(COUNT(Table1[Answer]),Table1[Answer]="No") var AnswerAl=CALCULATE(COUNT(Table1[Answer]), ALL(Table1[Question])) return DIVIDE(AnswerNo,AnswerAl,BLANK())
Please feel free to ask it it does not work because it works on my side.
Ninter
Hi @Leeny127,
Please modify your data with Power Query by unpivoting all the anwer and keeping the student field.
Then load it in the power pivot model and you can use this formula where I called my table(Table1), and the 3 fields Student, Answer and Question:
Measure = var AnswerNo=CALCULATE(COUNT(Table1[Answer]),Table1[Answer]="No") var AnswerAl=CALCULATE(COUNT(Table1[Answer]), ALL(Table1[Question])) return DIVIDE(AnswerNo,AnswerAl,BLANK())
Please feel free to ask it it does not work because it works on my side.
Ninter
Starting December 3, join live sessions with database experts and the Fabric product team to learn just how easy it is to get started.
March 31 - April 2, 2025, in Las Vegas, Nevada. Use code MSCUST for a $150 discount! Early Bird pricing ends December 9th.
User | Count |
---|---|
87 | |
87 | |
84 | |
66 | |
49 |
User | Count |
---|---|
127 | |
109 | |
93 | |
70 | |
67 |