diff options
author | gebele <gebele@in-silico.ch> | 2017-05-04 11:33:54 +0000 |
---|---|---|
committer | gebele <gebele@in-silico.ch> | 2017-05-04 11:33:54 +0000 |
commit | 1cf0938be3cc81e426030df9b1a1e3f534fa5fc2 (patch) | |
tree | aec19bd9dad554080c62c1f6317a4d637d3781b9 /views/prediction.haml | |
parent | 6e2dacfee8e52175ef3ccc79da3d3dc21380683f (diff) |
bumped version;adjustments for updated lazar library
Diffstat (limited to 'views/prediction.haml')
-rw-r--r-- | views/prediction.haml | 32 |
1 files changed, 24 insertions, 8 deletions
diff --git a/views/prediction.haml b/views/prediction.haml index 77d7524..12a1fde 100644 --- a/views/prediction.haml +++ b/views/prediction.haml @@ -23,14 +23,15 @@ = "#{@models[i].endpoint.gsub('_', ' ')} (#{@models[i].species})" / check for prediction - - if prediction[:neighbors].size > 0 + /- if prediction[:neighbors].size > 0 + - if prediction[:neighbors] and !prediction[:value].nil? %p / show model type (classification|regression) %b Type: = type %p / check for database hit - - if prediction[:warning] =~ /\b(identical)\b/i + - if prediction[:info] =~ /\b(identical)\b/i - @dbhit[i] = true / show message about dbhit and measurements @@ -77,15 +78,30 @@ %br = "#{prediction[:probabilities].keys[1]}: #{prediction[:probabilities].values[1].signif(3)}" - / show warnings + / show warnings and info %p - - if !prediction[:warning].nil? - %b Warnings: - %a.btn.glyphicon.glyphicon-info-sign{:href=>"javascript:void(0)", :title=>"Warnings", :tabindex=>"0", data: {trigger:"focus", toggle:"popover", placement:"auto", html:"true", content:"#{prediction[:warning]}"}} + - if !prediction[:info].blank? + %b info: + %br + %p=prediction[:info].sub(/excluded/, "excluded<br>") + - if !prediction[:warnings].blank? + %b warnings: + - prediction[:warnings].each do |warning| + %br + %p=warning + %p=warning.sub(/substances/, "substances<br>").sub(/prediction\:/, "prediction\:<br>") - else + %br - @dbhit[i] = false - %p - = "Not enough similar compounds </br>in training dataset." + - if !prediction[:info].blank? + %b info: + %br + %p=prediction[:info].sub(/excluded/, "excluded<br>") + - if !prediction[:warnings].blank? + %b warnings: + - prediction[:warnings].each do |warning| + %br + %p=warning.sub(/substances/, "substances<br>").sub(/prediction\:/, "prediction\:<br>") / always show the neighbors table, message is given there = haml :neighbors, :layout => false, :model_type => @model_types, :dbhit => @dbhit |