Class CSVMeasureOutput
java.lang.Object
dataAnalysis.MeasureOutput
dataAnalysis.measureOutputs.CSVMeasureOutput
This class implements a csv output for measure class.
File output:
File output:
| Mean Value | Mean Value Lower Limit | Mean Value Upper Limit | Discarded Samples | Analyzed Samples | Max Samples |
- Author:
- Francesco Radaelli
-
Field Summary
Fields inherited from class MeasureOutput
measure -
Constructor Summary
ConstructorsConstructorDescriptionCSVMeasureOutput(Measure measure, boolean append) Constructor of a CSVMeasureOutput object, using a file.CSVMeasureOutput(Measure measure, boolean append, String fileName) Constructor of a CSVMeasureOutput object. -
Method Summary
Modifier and TypeMethodDescriptionvoidOverrides this method to implement the way in which the final measure should be written on an output stream.Returns the output file for this measure outputvoidwrite(double sample, double weight) Overrides this method to implement the way in which each measure should be written on an output stream.
-
Constructor Details
-
CSVMeasureOutput
Constructor of a CSVMeasureOutput object.- Parameters:
measure- the measure to be sent in outputappend- true to write at the end of the file (of course it is useful only if a file is used)fileName- the name of the file; if null the output will be sent on the standard output- Throws:
IOException
-
CSVMeasureOutput
Constructor of a CSVMeasureOutput object, using a file.- Parameters:
measure- the measure to be sent in outputappend- true to write at the end of the file (of course it is useful only if a file is used)- Throws:
IOException
-
-
Method Details
-
write
public void write(double sample, double weight) Description copied from class:MeasureOutputOverrides this method to implement the way in which each measure should be written on an output stream. This method is called for every sample.- Specified by:
writein classMeasureOutput- Parameters:
sample- the measure sampleweight- the sample weight
-
finalizeMeasure
public void finalizeMeasure()Description copied from class:MeasureOutputOverrides this method to implement the way in which the final measure should be written on an output stream. This method is called at the end of a measure.- Specified by:
finalizeMeasurein classMeasureOutput
-
getOutputFile
Description copied from class:MeasureOutputReturns the output file for this measure output- Specified by:
getOutputFilein classMeasureOutput- Returns:
- a reference to the output file
-