diff options
author | gebele <gebele@in-silico.ch> | 2017-01-18 14:17:02 +0000 |
---|---|---|
committer | gebele <gebele@in-silico.ch> | 2017-01-18 14:17:02 +0000 |
commit | dd8b986e198552ce865aa5500335043f60a0eef3 (patch) | |
tree | f5c06159d0a529f263ea25f6354f89825fc41410 /test/nanomaterial-model-validation.rb | |
parent | 76912e72cf52c2a10423226ababb2b6d7f4b84ca (diff) | |
parent | d7504cc422bbaeee3546589d87e7baeb4e977c0b (diff) |
fixed merge
Diffstat (limited to 'test/nanomaterial-model-validation.rb')
-rw-r--r-- | test/nanomaterial-model-validation.rb | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/test/nanomaterial-model-validation.rb b/test/nanomaterial-model-validation.rb index b91c389..9eaa17d 100644 --- a/test/nanomaterial-model-validation.rb +++ b/test/nanomaterial-model-validation.rb @@ -8,7 +8,7 @@ class NanomaterialValidationModelTest < MiniTest::Test end def test_default_nanomaterial_validation_model - validation_model = Model::NanoValidation.create + validation_model = Model::Validation.from_enanomapper [:endpoint,:species,:source].each do |p| refute_empty validation_model[p] end @@ -39,7 +39,7 @@ class NanomaterialValidationModelTest < MiniTest::Test :prediction => { :method => "OpenTox::Algorithm::Regression.weighted_average" }, :feature_selection => nil } - validation_model = Model::NanoValidation.create algorithms: algorithms + validation_model = Model::Validation.from_enanomapper algorithms: algorithms assert validation_model.regression? refute validation_model.classification? validation_model.crossvalidations.each do |cv| @@ -50,6 +50,5 @@ class NanomaterialValidationModelTest < MiniTest::Test assert_includes nanoparticle.dataset_ids, @training_dataset.id prediction = validation_model.predict nanoparticle refute_nil prediction[:value] - assert_includes prediction[:prediction_interval][0]..prediction[:prediction_interval][1], prediction[:measurements].median, "This assertion assures that measured values are within the prediction interval. It may fail in 5% of the predictions." end end |