netkit.classifiers.nonrelational
Class ClassPrior

java.lang.Object
  extended by netkit.classifiers.ClassifierImp
      extended by netkit.classifiers.nonrelational.ClassPrior
All Implemented Interfaces:
Classifier, Configurable

public final class ClassPrior
extends ClassifierImp

This classifier is static and always returns the class marginals.

Author:
Sofus A. Macskassy (sofmac@gmail.com)

Field Summary
 
Fields inherited from class netkit.classifiers.ClassifierImp
attribute, classPrior, clsIdx, graph, keyIndex, logger, nodeType, right, tmpVector, useIntrinsic, vectorClsIdx
 
Constructor Summary
ClassPrior()
           
 
Method Summary
 boolean estimate(Node node, double[] result)
          Copies the class marginals into the 'result' array.
 java.lang.String getDescription()
           
 java.lang.String getName()
           
 java.lang.String getShortName()
           
 java.lang.String toString()
           
 
Methods inherited from class netkit.classifiers.ClassifierImp
addListener, classify, classify, clearListeners, configure, estimate, estimate, getAttributeNames, getDefaultConfiguration, getLogger, getNofifyListeners, induceModel, makeVector, notifyListeners, notifyListeners, removeListener, reset, setNofityListeners
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

ClassPrior

public ClassPrior()
Method Detail

getShortName

public java.lang.String getShortName()
Returns:
'ClassPrior'

getName

public java.lang.String getName()
Returns:
'ClassPrior'

getDescription

public java.lang.String getDescription()
Returns:
'This classifier is static and always returns the class marginals.'

estimate

public boolean estimate(Node node,
                        double[] result)
Copies the class marginals into the 'result' array.

Parameters:
node - Ignored
result - Filled with the class marginals
Returns:
true

toString

public java.lang.String toString()
Overrides:
toString in class java.lang.Object