summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorgebele <gebele@in-silico.ch>2017-01-20 14:08:34 +0000
committergebele <gebele@in-silico.ch>2017-01-20 14:08:34 +0000
commit0c6f7d42c9b60493e24df56252ddba36b834a684 (patch)
tree4fd8a42c4b95957b052873b6f0b4012112736de8
parent1106dbf48614d5329d601e12e53684ac6bd4188c (diff)
fixed view for single value probability
-rw-r--r--views/prediction.haml5
1 files changed, 3 insertions, 2 deletions
diff --git a/views/prediction.haml b/views/prediction.haml
index 1b8d38d..77d7524 100644
--- a/views/prediction.haml
+++ b/views/prediction.haml
@@ -73,8 +73,9 @@
- unless prediction[:probabilities].nil?
%br
= "#{prediction[:probabilities].keys[0]}: #{prediction[:probabilities].values[0].signif(3)}"
- %br
- = "#{prediction[:probabilities].keys[1]}: #{prediction[:probabilities].values[1].signif(3)}"
+ - if prediction[:probabilities].size == 2
+ %br
+ = "#{prediction[:probabilities].keys[1]}: #{prediction[:probabilities].values[1].signif(3)}"
/ show warnings
%p