improve stats handling

This commit is contained in:
Ross
2024-01-08 22:46:46 +00:00
parent 9d05e5d34e
commit d6f1de2036
10 changed files with 166 additions and 11 deletions
+20
View File
@@ -0,0 +1,20 @@
{% extends 'base.html' %}
{% block content %}
<h2>{{exam.name}}</h2>
{% if exam.stats_candidates < 4 %}
Not enough data points...
{% else %}
<div id="stats-plot">{{exam.stats_graph|safe}}</div>
Questions: <span id="question-number">{{question_number}}</span><br />
Available marks: {{exam_stats_max_possible}}<br />
Mean: {{exam.stats_mean}}, Median {{exam.stats_median}}, Mode {{exam.stats_mode}}<br />
Top score: {{exam.stats_max}}
<p class="small-gray">Note: scores < 10% of the total score are excluded from these statistics
{% endif %}
{% endblock %}