From 8d325866dd7cacdd04bd2306a9144a5e7300c7c8 Mon Sep 17 00:00:00 2001 From: Christoph Helma Date: Thu, 13 Oct 2016 10:11:09 +0200 Subject: molecular_weight fixed --- lib/compound.rb | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'lib/compound.rb') diff --git a/lib/compound.rb b/lib/compound.rb index 0f178ce..ca9d5e3 100644 --- a/lib/compound.rb +++ b/lib/compound.rb @@ -75,9 +75,10 @@ module OpenTox fingerprints[type] end - def calculated_properties types=["OPENBABEL"] + def calculated_properties types=["PhysChem::OPENBABEL"] descriptors = [] types.each do |t| + p t descriptors += PhysChem.descriptors OpenTox.const_get(t) end # TODO: speedup java descriptors @@ -304,7 +305,7 @@ module OpenTox # @return [Float] molecular weight def molecular_weight mw_feature = PhysChem.find_or_create_by(:name => "Openbabel.MW") - calculated_physchem([mw_feature])[mw_feature.id.to_s] + calculated_properties[mw_feature.id.to_s] end private -- cgit v1.2.3