summaryrefslogtreecommitdiff
path: root/views/neighbors.haml
diff options
context:
space:
mode:
authorChristoph Helma <helma@in-silico.de>2009-07-24 12:40:54 +0200
committerChristoph Helma <helma@in-silico.de>2009-07-24 12:40:54 +0200
commitd0836c7afa9007bb44d11e8f4b632eb66f7bb5ba (patch)
tree22aeecac379be9338840936409a1938e6ccb11cf /views/neighbors.haml
Initial import of lazar-webservice-gui
Diffstat (limited to 'views/neighbors.haml')
-rw-r--r--views/neighbors.haml34
1 files changed, 34 insertions, 0 deletions
diff --git a/views/neighbors.haml b/views/neighbors.haml
new file mode 100644
index 0000000..5bf5aba
--- /dev/null
+++ b/views/neighbors.haml
@@ -0,0 +1,34 @@
+&rarr;
+%a{ :href => "/#{params[:id]}" } Enter structure
+&rarr; Prediction
+
+%h1= @lazar['endpoint'].gsub(/\"|\'/,'')
+
+%table
+ %tr
+ %th Structure
+ %th Prediction
+ %th Measured activity
+ %tr
+ %td
+ %img{:src => "http://cactus.nci.nih.gov/chemical/structure/#{URI.encode(@lazar['smiles'])}/image", :alt => "#{@lazar['smiles']}"}
+ %td
+ %p= @lazar['prediction']
+ %p
+ (
+ = @lazar['confidence']
+ )
+ %td= @lazar['database_activity']
+ %tr
+ %td{:colspan => 4} Neighbors
+ %tr
+ %th Structure
+ %th Similarity
+ %th Measured activity
+
+ - @lazar['neighbors']['neighbor'].each do |neighbor|
+ %tr
+ %td
+ %img{:src => "http://cactus.nci.nih.gov/chemical/structure/#{URI.encode(neighbor['smiles'])}/image", :alt => "#{neighbor['smiles']}"}
+ %td= neighbor['similarity']
+ %td= neighbor['activity']