From d4eb231a35c23a5fdb36fd6220b5ab706e7528ba Mon Sep 17 00:00:00 2001 From: mguetlein Date: Mon, 14 Feb 2011 17:48:26 +0100 Subject: read from subjectcookie, fix read feature_type --- lib/feature.rb | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) (limited to 'lib/feature.rb') diff --git a/lib/feature.rb b/lib/feature.rb index be063dd..c0729a7 100644 --- a/lib/feature.rb +++ b/lib/feature.rb @@ -16,8 +16,14 @@ module OpenTox # provides domain (possible target values) of classification feature # @return [Array] list with possible target values def domain - #TODO derieve from metadata / ontology - return [true, false] + if metadata[OT.acceptValue] + raise "accept value found, remove hack and implement correctly" + else + if @uri=~/feature\/26221/ || @uri=~/feature\/221726/ + return ["mutagen" , "nonmutagen"] + end + return [true, false] + end end # provides feature type, possible types are "regression" or "classification" -- cgit v1.2.3