All Packages  Class Hierarchy  This Package  Previous  Next  Index  WEKA's home

Class weka.experiment.InstancesResultListener

java.lang.Object
    |
    +----weka.experiment.CSVResultListener
            |
            +----weka.experiment.InstancesResultListener

public class InstancesResultListener
extends CSVResultListener
InstancesResultListener outputs the received results in arff format to a Writer. All results must be received before the instances can be written out.

Version:
$Revision: 1.5 $
Author:
Len Trigg (trigg@cs.waikato.ac.nz)

Constructor Index

 o InstancesResultListener()
 

Method Index

 o acceptResult(ResultProducer, Object[], Object[])
Collects each instance and adjusts the header information.
 o globalInfo()
Returns a string describing this result listener
 o postProcess(ResultProducer)
Perform any postprocessing.
 o preProcess(ResultProducer)
Prepare for the results to be received.

Constructor Detail

 o InstancesResultListener
public InstancesResultListener()

Method Detail

 o globalInfo
public java.lang.String globalInfo()
          Returns a string describing this result listener
Returns:
a description of the result listener suitable for displaying in the explorer/experimenter gui
Overrides:
globalInfo in class CSVResultListener
 o preProcess
public void preProcess(ResultProducer rp) throws java.lang.Exception
          Prepare for the results to be received.
Parameters:
rp - the ResultProducer that will generate the results
Throws:
java.lang.Exception - if an error occurs during preprocessing.
Overrides:
preProcess in class CSVResultListener
 o postProcess
public void postProcess(ResultProducer rp) throws java.lang.Exception
          Perform any postprocessing. When this method is called, it indicates that no more results will be sent that need to be grouped together in any way.
Parameters:
rp - the ResultProducer that generated the results
Throws:
java.lang.Exception - if an error occurs
Overrides:
postProcess in class CSVResultListener
 o acceptResult
public void acceptResult(ResultProducer rp,
                         java.lang.Object key[],
                         java.lang.Object result[]) throws java.lang.Exception
          Collects each instance and adjusts the header information.
Parameters:
rp - the ResultProducer that generated the result
key - The key for the results.
result - The actual results.
Throws:
java.lang.Exception - if the result could not be accepted.
Overrides:
acceptResult in class CSVResultListener

All Packages  Class Hierarchy  This Package  Previous  Next  Index  WEKA's home