summaryrefslogtreecommitdiff
path: root/lib/compound.rb
diff options
context:
space:
mode:
authorChristoph Helma <helma@in-silico.ch>2016-05-05 16:14:02 +0200
committerChristoph Helma <helma@in-silico.ch>2016-05-05 16:14:02 +0200
commitab7b37541b4f8a762be737009631d3eefd898b4a (patch)
treee3c1d1fcc39ce58d151b498e810c5631931486a1 /lib/compound.rb
parent05386e748270c337c66f6f379317ea4b25905236 (diff)
ambit mirror, import from mirrored json, proteomics import
Diffstat (limited to 'lib/compound.rb')
-rw-r--r--lib/compound.rb6
1 files changed, 3 insertions, 3 deletions
diff --git a/lib/compound.rb b/lib/compound.rb
index c2ce5d0..143c4f2 100644
--- a/lib/compound.rb
+++ b/lib/compound.rb
@@ -77,7 +77,7 @@ module OpenTox
def physchem descriptors=PhysChem.openbabel_descriptors
# TODO: speedup java descriptors
- calculated_ids = physchem_descriptors.keys
+ calculated_ids = physchem.keys
# BSON::ObjectId instances are not allowed as keys in a BSON document.
new_ids = descriptors.collect{|d| d.id.to_s} - calculated_ids
descs = {}
@@ -90,11 +90,11 @@ module OpenTox
# avoid recalculating Cdk features with multiple values
descs.keys.uniq.each do |k|
descs[k].send(k[0].downcase,k[1],self).each do |n,v|
- physchem_descriptors[algos[n].id.to_s] = v # BSON::ObjectId instances are not allowed as keys in a BSON document.
+ physchem[algos[n].id.to_s] = v # BSON::ObjectId instances are not allowed as keys in a BSON document.
end
end
save
- physchem_descriptors.select{|id,v| descriptors.collect{|d| d.id.to_s}.include? id}
+ physchem.select{|id,v| descriptors.collect{|d| d.id.to_s}.include? id}
end
def smarts_match smarts, count=false