Commit efe5ec36 authored by Janez K's avatar Janez K
Browse files

added new features to visualizations

parent 22932682
...@@ -147,7 +147,7 @@ $(function () { ...@@ -147,7 +147,7 @@ $(function () {
}, },
{% endif %} {% endif %}
{% if 'accuracy' in input_dict.eval_results.0 %}{ {% if 'accuracy' in input_dict.eval_results.0 %}{
name: 'accuracy', name: 'Accuracy',
data: [ data: [
{% for item in input_dict.eval_results %} {% for item in input_dict.eval_results %}
{ y: {{ item.accuracy }}, index: {{forloop.counter0}} }, { y: {{ item.accuracy }}, index: {{forloop.counter0}} },
...@@ -155,7 +155,18 @@ $(function () { ...@@ -155,7 +155,18 @@ $(function () {
], ],
visible: true, visible: true,
showInLegend: true showInLegend: true
} },
{% endif %}
{% if 'auc' in input_dict.eval_results.0 %}{
name: 'AUC',
data: [
{% for item in input_dict.eval_results %}
{ y: {{ item.auc }}, index: {{forloop.counter0}} },
{% endfor %}
],
visible: true,
showInLegend: true
},
{% endif %} {% endif %}
] ]
}); });
......
...@@ -11,6 +11,12 @@ ...@@ -11,6 +11,12 @@
<i>F</i><span style="vertical-align:-25%; margin-left:-0.1em; font-size:75%;">{% if beta == 1 %}1{% else %}{{beta}}{% endif %}</span> score <i>F</i><span style="vertical-align:-25%; margin-left:-0.1em; font-size:75%;">{% if beta == 1 %}1{% else %}{{beta}}{% endif %}</span> score
{% endwith %} {% endwith %}
</th> </th>
{% if 'accuracy' in input_dict.eval_results.0 %}
<th class="tablecellcenter"> Classification accuracy </th>
{% endif %}
{% if 'auc' in input_dict.eval_results.0 %}
<th class="tablecellcenter"> AUC </th>
{% endif %}
</tr> </tr>
{% for item in input_dict.eval_results %} {% for item in input_dict.eval_results %}
<tr class="tablerow{{widget.pk}}"> <tr class="tablerow{{widget.pk}}">
...@@ -21,6 +27,12 @@ ...@@ -21,6 +27,12 @@
{{ item.precision|floatformat:"2" }}{% if 'std_pr' in item %}&nbsp;&plusmn;&nbsp;{{item.std_pr|floatformat:"2"}}{% endif %} </td> {{ item.precision|floatformat:"2" }}{% if 'std_pr' in item %}&nbsp;&plusmn;&nbsp;{{item.std_pr|floatformat:"2"}}{% endif %} </td>
<td class="tablecellright"> <td class="tablecellright">
{{ item.fscore|floatformat:"2" }}{% if 'std_fs' in item %}&nbsp;&plusmn;&nbsp;{{item.std_fs|floatformat:"2"}}{% endif %} </td> {{ item.fscore|floatformat:"2" }}{% if 'std_fs' in item %}&nbsp;&plusmn;&nbsp;{{item.std_fs|floatformat:"2"}}{% endif %} </td>
{% if 'accuracy' in input_dict.eval_results.0 %}
<td class="tablecellright">{{ item.accuracy }}%</td>
{% endif %}
{% if 'auc' in input_dict.eval_results.0 %}
<td class="tablecellright">{{ item.auc }}%</td>
{% endif %}
</tr> </tr>
{% endfor %} {% endfor %}
</table> </table>
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment