summaryrefslogtreecommitdiff
path: root/views
diff options
context:
space:
mode:
authorgebele <gebele@in-silico.ch>2013-05-21 16:17:44 +0200
committergebele <gebele@in-silico.ch>2013-05-21 16:17:44 +0200
commit5cd95518ce65906ee80a94dcb3b16c3975e9bc80 (patch)
treefd5597e7447423930d6d3df7d4a2cac400de40ea /views
parent03f40594581a3046ebba74239ca70e598ec98ad6 (diff)
minor changes, added customized tooltips
Diffstat (limited to 'views')
-rw-r--r--views/details.haml2
-rw-r--r--views/layout.haml20
-rw-r--r--views/neighbours.haml21
-rw-r--r--views/predict.haml7
-rw-r--r--views/prediction.haml36
5 files changed, 68 insertions, 18 deletions
diff --git a/views/details.haml b/views/details.haml
index ff77783..1697831 100644
--- a/views/details.haml
+++ b/views/details.haml
@@ -12,7 +12,7 @@
%br
%b
Names:
- %p= @names
+ %p= @names.gsub(",", ";\t")
%br
%b
InChI:
diff --git a/views/layout.haml b/views/layout.haml
index b6606a1..12874c4 100644
--- a/views/layout.haml
+++ b/views/layout.haml
@@ -7,15 +7,16 @@
%link{ :href=>"/stylesheets/screen.css", :media=>"screen, projection", :rel=>"stylesheet", :type=>"text/css"}
%link{ :href=>"/stylesheets/jquery-ui.css", :rel=>"stylesheet"}
%script{:src=>"/javascripts/jquery-1.9.1.min.js", :type=>"text/javascript"}
- %script{ :src=>"/javascripts/jquery-ui.js", :type=>"text/javascript"}
+ %script{ :src=>"/javascripts/jquery-ui.min.js", :type=>"text/javascript"}
%script{ :src=>"/javascripts/lazar-gui.js", :type=>"text/javascript"}
%script{:src=>"/javascripts/jquery.tablesorter.min.js", :type=>"text/javascript"}
%script{:src=>"/javascripts/jquery.bpopup.min.js", :type=>"text/javascript"}
+ %script{:src=>"/javascripts/jquery.tools.min.js", :type=>"text/javascript"}
%body
.logo
- %a{:href=> "http://www.in-silico.ch/", :rel=> "external"}
+ %a{:href=> to("/predict")}
%img{:src=>"/images/ist_logo.png"}
%h1 Lazar Toxicity Predictions
%hr
@@ -42,6 +43,21 @@
return false;
});
});
+ $('a#confidence').tooltip({
+ predelay: 800,
+ position: 'bottom center',
+ offset: [-400, 0],
+ });
+ $('a#similarity').tooltip({
+ predelay: 800,
+ position: 'bottom center',
+ offset: [-400, 0],
+ });
+ $('a#measured_activity').tooltip({
+ predelay: 800,
+ position: 'bottom center',
+ offset: [-400, 0],
+ });
});
#back-top
%a{:href => ""}^ top ^
diff --git a/views/neighbours.haml b/views/neighbours.haml
index ae93aff..5993caa 100644
--- a/views/neighbours.haml
+++ b/views/neighbours.haml
@@ -52,9 +52,26 @@
%th
Compound
%th
- Measured Activity
+ %a{:href=>"#", :title=>"", :id=>"measured_activity"} Measured Activity
+ .tooltip{:style=>"font-weight: normal; font-size: 1em; text-align: left;"}
+ Experimental result(s) from the training dataset.
%th
- Similarity
+ %a{:href=>"#", :title=>"", :id=>"similarity"} Similarity
+ .tooltip{:style=>"font-weight: normal; font-size: 1em; text-align: left;"}
+ %dt
+ Similarity
+ %dd
+ %code lazar
+ calculates
+ %em
+ activity specific
+ similarities based on the presence of statistically significant fragments.
+ This procedure will
+ %ul
+ %li consider only those parts of a chemical structure that are relevant for a particular endpoint
+ %li ignore inert parts of the structure
+ %li lead to different similarities, depending on the toxic endpoint
+ Similarities of 1 may be encountered even for structurally dissimilar compounds, because inert parts are ignored.
%th
Details
-#%tbody
diff --git a/views/predict.haml b/views/predict.haml
index 8528c31..64be9df 100644
--- a/views/predict.haml
+++ b/views/predict.haml
@@ -25,14 +25,14 @@
/ whole site content needs to be in one form. Input and checkboxes are checked by js functions.
%form{:name => "form", :action => to('/predict'), :method => "post", :enctype => "multipart/form-data", :onsubmit => "return !!(checksmiles() & checkboxes())" }
%fieldset#top
- %a{:href => "#insert", :id => "linkInsert"}
+ %a{:href => "#", :id => "linkInsert"}
%h1 1. Draw or insert your compound
:javascript
$("a#linkInsert").click(function () {
$("#insert").toggle();
document.location = document.location + "#" + "insert";
});
- #insert{:style=>"display:none"}
+ #insert{:style=>"display: none"}
%p
%label &nbsp;
.jme
@@ -49,8 +49,9 @@
%label{:for => 'identifier'}
or enter the
%a{:href => "http://en.wikipedia.org/wiki/Simplified_molecular_input_line_entry_specification", :rel => "external"} SMILES
- string
+ string:
%input{:type => 'text', :name => 'identifier', :id => 'identifier', :size => '60'}
+
.close
= hide_link "#insert"
diff --git a/views/prediction.haml b/views/prediction.haml
index 1e67cbd..4646513 100644
--- a/views/prediction.haml
+++ b/views/prediction.haml
@@ -2,7 +2,8 @@
.back
%h1
%img{:src=>"/images/arrow_left_float.png", :alt=>"arrow"}
- %a{:href => to('/predict')} New Prediction
+ %a{:href => to('/predict')} New Prediction
+
/ displays all prediction results
.overview
%table{:width=>"100%", :cellspacing=>"1", :id=>"overview"}
@@ -10,11 +11,21 @@
%tr
%caption
%h2 Prediction Results:
- %i= @identifier
+
%tbody
%tr
%td{:id=>"compound"}
- %img{:src=>"#{@compound.uri}/image", :alt=>"image not available", :width=>"100"}
+ %a{:href => to("/prediction/#{CGI.escape(@compound.uri)}/details"), :id=>"linkCompound", :target=>"details_overview"}
+ %img{:src=>"#{@compound.uri}/image", :alt=>"image not available", :width=>"100"}
+ %br
+ %br
+ %img{:src=>"/images/arrow_up_float.png", :alt=>"arrow"}
+ :javascript
+ $(function() {
+ $("a#linkCompound").on('click', function(e) {
+ $('#iframe_overview').bPopup();
+ });
+ });
- count=0
/ var for rule to load neighbours page.
- @@neighbours_available = 1
@@ -32,7 +43,12 @@
= "Result:\n"
%b= p.data_entries[0][0] != nil ? p.data_entries[0][0] : "No prediction result"
%br
- = "Confidence:\n"
+ %a{:href=>"#", :title=>"", :id=>"confidence"} Confidence
+ .tooltip{:style=>"font-weight: normal; font-size: 1em; width: 50%; text-align: left;"}
+ Indicates the applicability domain of a model.
+ Predictions with a high confidence can be expected to be more reliable than predictions with low confidence.
+ Confidence values may take any value between 0 and 1.
+ For most models confidence > 0.025 is a sensible (hard) cutoff to distiguish between reliable and unreliable predictions.
= p.data_entries[0][1].round(3)
%br
%a{:href=> "#tabs", :id=>"link#{count}"}
@@ -45,9 +61,9 @@
});
- count+=1
-- if @@neighbours_available > 1
- = haml :neighbours, :layout => false
-- else
- %h2
- no neighbours available
-
+ - if @@neighbours_available > 1
+ = haml :neighbours, :layout => false
+ - else
+ %h2
+ no neighbours available
+%iframe{:id=>"iframe_overview", :name=>"details_overview", :height=>"80%", :width=>"80%", :style=>"display:none;border:0px"}