10 Replies Latest reply on Feb 24, 2017 6:09 AM by Norbert Maijoor

Pass and Fail Rates Calculations

Help I am still a newbie in Tableau. I am trying to analyse  results of our students who sat for exams. The results are categorised per subject with the following symbols

A = Pass, B = Pass, C= Pass, D= Fail, E= Fail, U= Fail and X= Fail . I am not yet well polished on calculations and parameters. I need assistance on how i can see the number of students who passed (pass rate) as a whole. And the number of students who passed per Region (pass rate) and if possible per school (pass rate).

• 1. Re: Pass and Fail Rates Calculations

Hi Tawa,

I am not able to open the packaged worksheet as I don't have latest version of Tableau

1. Number of students who passed as whole. There are many ways, but one thing I can rem off hand is

Create a Calculated field or on the fly on shelf

= SUM(IF CONTAINS ("A,B,C",GRADE) THEN 1 END ELSE 0)/TOTAL(COUNT OF STUDENTS)

or

SUM(IF CONTAINS ("A,B,C",GRADE) THEN 1 END ELSE 0)/sum(IF CONTAINS ("A,B,C,D,E,U,X",GRADE) THEN 1 END ELSE 0)

Second part you can use the same calculation in rows  and drag region and or school to columns get the breakdown.

HTH,

Peter

1 of 1 people found this helpful
• 2. Re: Pass and Fail Rates Calculations

Hi Tawa,

Find my approach as reference below and stored in original threat in version 9.3

I "grouped" all values to A, B, C, D, E, U X & Others

then I defined "Pass - Fail"

f [Symbol (group)]='A' then "PASS"

elseif [Symbol (group)]='B' then "PASS"

elseif [Symbol (group)]='C' then "PASS"

elseif [Symbol (group)]='D' then "FAIL"

elseif [Symbol (group)]='E' then "FAIL"

elseif [Symbol (group)]='U' then "FAIL"

elseif [Symbol (group)]='X' then "FAIL"

else "Other"

END

Defined count of Students

count([Surname])

total

Per Region

Per School

Regards,

Norbert

2 of 2 people found this helpful
• 3. Re: Pass and Fail Rates Calculations

Thank you so much. This is exactly what i was looking for. If i am to drill down into the number of students that sat for the exam, and the number of students who had a total 5 passes(5 subjects). I hope i am not asking for too much

• 4. Re: Pass and Fail Rates Calculations

Hi Tawa,

No problem. You are welcome.

countd([Surname])= 1605 (sheet 5)

Count student with 5 passes or more: if attr([PASS FAIL])="PASS" and count([Surname])>=5 then 1 END = 74(sheet 6)

Please validate and let me know.

Regards,

Norbert

1 of 1 people found this helpful
• 5. Re: Pass and Fail Rates Calculations

Hi Norbert

Thank you. It does check out like a charm. Many thanks for the assistance.

• 6. Re: Pass and Fail Rates Calculations

Hi Tawa,

• 7. Re: Pass and Fail Rates Calculations

Hi Norbert

I have created a dashboard and tried to use the calculations. There is a disparity with what i got from my manual count. May you assist in troubleshooting the work book. E.g 2,598 sat for the exams and were captured in my database. The overall pass rate and the number of students with at least 5 subject passes in one goal, are not showing correctly. Help me and explain where its going wrong.

Thanks,

Tawa

• 8. Re: Pass and Fail Rates Calculations

Hi Tawa,

I reviewed the dashboard and cleaned it up. Please validate. When I look at the data I find a huge amount of duplicates, wrong notation etc. Please consider to proper validation of your dataset.

Regards,

Norbert

1 of 1 people found this helpful
• 9. Re: Pass and Fail Rates Calculations

Thank you so much Norbet.  i will start working on the dataset.

• 10. Re: Pass and Fail Rates Calculations

Hi Tawa,

You are welcome. Have a nice weekend.