Sha256: 155dac9135542126c6a0874289bcdbdf6aad65ca563eef9afbd68e2a9154a71e
Contents?: true
Size: 654 Bytes
Versions: 2
Compression:
Stored size: 654 Bytes
Contents
require_relative "setup.rb" class ValidationModelTest < MiniTest::Test def test_validation_model m = Model::Validation.from_csv_file "#{DATA_DIR}/hamster_carcinogenicity.csv" [:endpoint,:species,:source].each do |p| refute_empty m[p] end assert m.classification? refute m.regression? m.crossvalidations.each do |cv| assert cv.accuracy > 0.74, "Crossvalidation accuracy (#{cv.accuracy}) should be larger than 0.75. This may happen due to an unfavorable training/test set split." end prediction = m.predict Compound.from_smiles("CCCC(NN)C") assert_equal "true", prediction[:value] m.delete end end
Version data entries
2 entries across 2 versions & 1 rubygems
Version | Path |
---|---|
lazar-1.0.1 | test/model-validation.rb |
lazar-1.0.0 | test/model-validation.rb |