summaryrefslogtreecommitdiff
path: root/fminer.rb
diff options
context:
space:
mode:
Diffstat (limited to 'fminer.rb')
-rw-r--r--fminer.rb4
1 files changed, 2 insertions, 2 deletions
diff --git a/fminer.rb b/fminer.rb
index f796ee4..5fda98f 100644
--- a/fminer.rb
+++ b/fminer.rb
@@ -349,9 +349,9 @@ post '/fminer/bbrc/?' do
# Add fminer results to feature dataset along owd
which_row = @@fminer.training_dataset.compounds.inject({}) { |h,id| h[id]=0; h }
- fminer_compounds_owd.each { |compound|
+ unused_compounds = fminer_compounds_owd - fminer_results.keys
+ (fminer_compounds_owd - unused_compounds).each { |compound|
feature_dataset.add_compound(compound) # add compounds *in order*
- # select appropriate feature value
fminer_results[compound].each { |feature, values|
feature_dataset.add( compound, feature, values[which_row[compound]] )
}