Added subjectid.
authorDavid Vorgrimmler <vorgrimmlerdavid@gmx.de>
Wed, 20 Jun 2012 15:39:39 +0000 (17:39 +0200)
committerDavid Vorgrimmler <vorgrimmlerdavid@gmx.de>
Wed, 20 Jun 2012 15:39:39 +0000 (17:39 +0200)
lib/algorithm.rb
lib/compound.rb

index 00f7e4e..e2798b3 100644 (file)
@@ -593,7 +593,7 @@ module OpenTox
       # @param [Hash] required keys: compound, features, feature_dataset_uri, pc_type
       # @return [Hash] Hash with matching Smarts and number of hits 
       def self.lookup(params)
-        params[:compound].lookup(params[:features], params[:feature_dataset_uri],params[:pc_type], params[:lib],params[:subjectid])
+        params[:compound].lookup(params[:features], params[:feature_dataset_uri], params[:pc_type], params[:lib], params[:subjectid])
       end  
     end
 
index 3727c8c..e493278 100644 (file)
@@ -261,7 +261,7 @@ module OpenTox
       if entry.nil?
         temp_ds = OpenTox::Dataset.create(CONFIG[:services]["opentox-dataset"],subjectid); temp_ds.add_compound(self.uri); temp_uri = temp_ds.save(subjectid)
         uri = RestClientWrapper.post(File.join(CONFIG[:services]["opentox-algorithm"], "/pc/AllDescriptors"), {:dataset_uri => temp_uri, :pc_type => pc_type, :lib => lib, :subjectid => subjectid})
-        ds = OpenTox::Dataset.find(uri)
+        ds = OpenTox::Dataset.find(uri, subjectid)
         entry = ds.data_entries[self.uri]
         ds.delete(subjectid)
         temp_ds.delete(subjectid)