summaryrefslogtreecommitdiff
path: root/lazar.rb
diff options
context:
space:
mode:
Diffstat (limited to 'lazar.rb')
-rw-r--r--lazar.rb10
1 files changed, 5 insertions, 5 deletions
diff --git a/lazar.rb b/lazar.rb
index 210433f..4dede79 100644
--- a/lazar.rb
+++ b/lazar.rb
@@ -83,7 +83,7 @@ class LazarTest < Test::Unit::TestCase
create_model :dataset_uri => @@regression_training_dataset.uri
predict_compound OpenTox::Compound.from_smiles("c1ccccc1NN")
assert_in_delta @predictions.first.value(@compounds.first), 0.43, 0.2
- assert_equal 0.610, @predictions.first.confidence(@compounds.first).round_to(3)
+ assert_equal 0.61, @predictions.first.confidence(@compounds.first).round_to(2)
assert_equal 253, @predictions.first.neighbors(@compounds.first).size
cleanup
end
@@ -91,18 +91,18 @@ class LazarTest < Test::Unit::TestCase
def test_create_regression_prop_model
create_model :dataset_uri => @@regression_training_dataset.uri, :propositionalized => "true"
predict_compound OpenTox::Compound.from_smiles("c1ccccc1NN")
- assert_equal 0.610, @predictions.first.confidence(@compounds.first).round_to(3)
+ assert_equal 0.61, @predictions.first.confidence(@compounds.first).round_to(2)
assert_equal 253, @predictions.first.neighbors(@compounds.first).size
- assert_equal 131, @model.features.size
+ assert_equal 132, @model.features.size
cleanup
end
def test_create_regression_prop_nr_hits_model
create_model :dataset_uri => @@regression_training_dataset.uri, :propositionalized => "true", :nr_hits => "false"
predict_compound OpenTox::Compound.from_smiles("c1ccccc1NN")
- assert_equal 0.610, @predictions.first.confidence(@compounds.first).round_to(3)
+ assert_equal 0.61, @predictions.first.confidence(@compounds.first).round_to(2)
assert_equal 253, @predictions.first.neighbors(@compounds.first).size
- assert_equal 131, @model.features.size
+ assert_equal 132, @model.features.size
cleanup
end