mark.nlp.weka
Class WekaInstanceFactory

java.lang.Object
  |
  +--mark.nlp.classifiers.InstanceFactory
        |
        +--mark.nlp.weka.WekaInstanceFactory

public class WekaInstanceFactory
extends InstanceFactory

An InstanceFactory that constructs the information that weka.classifiers.Classifers need to train.


Constructor Summary
WekaInstanceFactory()
           
 
Method Summary
 java.lang.Object dataSetInformation(DataSet dataSet, FileCategorySet catSet, ObjectMap features)
          Returns information applicable to all instances in the data set.
 java.lang.Object instanceInformation(java.lang.Object dataSetInformation, SparseBagInstance instanceData)
          Returns information specific to a single instance.
 java.lang.Object instanceListInformation(java.lang.Object dataSetInformation, java.lang.String name, SparseBagInstance[] instances)
          Returns information specific to a list of instances.
 java.lang.String instanceListString(java.lang.Object dataSetInformation, java.lang.Object instanceListInformation)
          Given instance list information, generates a string that describes the instance list.
 
Methods inherited from class mark.nlp.classifiers.InstanceFactory
genFactory, genName
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

WekaInstanceFactory

public WekaInstanceFactory()
Method Detail

dataSetInformation

public java.lang.Object dataSetInformation(DataSet dataSet,
                                           FileCategorySet catSet,
                                           ObjectMap features)
                                    throws java.lang.Exception
Description copied from class: InstanceFactory
Returns information applicable to all instances in the data set.

Specified by:
dataSetInformation in class InstanceFactory
Parameters:
catSet - the file category set that describes the categories.
features - the features to use.
Returns:
the information.
java.lang.Exception
See Also:
InstanceFactory

instanceListInformation

public java.lang.Object instanceListInformation(java.lang.Object dataSetInformation,
                                                java.lang.String name,
                                                SparseBagInstance[] instances)
                                         throws java.lang.Exception
Description copied from class: InstanceFactory
Returns information specific to a list of instances.

Specified by:
instanceListInformation in class InstanceFactory
Parameters:
dataSetInformation - the information generated by dataSetInformation ().
instances - the list data.
java.lang.Exception
See Also:
InstanceFactory

instanceInformation

public java.lang.Object instanceInformation(java.lang.Object dataSetInformation,
                                            SparseBagInstance instanceData)
                                     throws java.lang.Exception
Description copied from class: InstanceFactory
Returns information specific to a single instance.

Specified by:
instanceInformation in class InstanceFactory
Parameters:
dataSetInformation - the information generated by dataSetInformation ().
instanceData - the instance data.
java.lang.Exception
See Also:
InstanceFactory

instanceListString

public java.lang.String instanceListString(java.lang.Object dataSetInformation,
                                           java.lang.Object instanceListInformation)
Description copied from class: InstanceFactory
Given instance list information, generates a string that describes the instance list.

Specified by:
instanceListString in class InstanceFactory
Parameters:
dataSetInformation - the information generated by dataSetInformation ().
instanceListInformation - the information generated by instanceListInformation ().
See Also:
InstanceFactory