Class: SvmToolkit::GeometricMean
- Defined in:
- lib/svm_toolkit/evaluators.rb
Overview
Defines an Evaluator returning the value of geometric mean.
Instance Method Summary collapse
-
#to_s ⇒ Object
Returns a string naming this evaluator and giving its value.
-
#value ⇒ Object
Returns the geometric mean.
Methods inherited from Evaluator
ClassPrecision, ClassRecall, FMeasure, Kappa, MatthewsCorrelationCoefficient, #add_result, #better_than?, #display, #initialize
Constructor Details
This class inherits a constructor from SvmToolkit::Evaluator
Instance Method Details
#to_s ⇒ Object
Returns a string naming this evaluator and giving its value.
163 164 165 |
# File 'lib/svm_toolkit/evaluators.rb', line 163 def to_s "Geometric mean: #{value}" end |
#value ⇒ Object
Returns the geometric mean.
157 158 159 |
# File 'lib/svm_toolkit/evaluators.rb', line 157 def value @cm.geometric_mean end |