Class VerboseCSVMeasureOutput
java.lang.Object
dataAnalysis.MeasureOutput
dataAnalysis.measureOutputs.VerboseCSVMeasureOutput
This class implements a csv output for measure class.
File output:
File output:
| Timestamp (simulation time) | Sample | Weight |
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final Stringstatic final Stringstatic final Stringstatic final String[]Fields inherited from class MeasureOutput
measure -
Constructor Summary
ConstructorsConstructorDescriptionVerboseCSVMeasureOutput(Measure measure, SimParameters simParameters, boolean isTerminalSimulation, int parametricStep) Constructor of a NewCSVMeasureOutput object, using a file. -
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.
-
Field Details
-
COLUMN_TS
- See Also:
-
COLUMN_SAMPLEVALUE
- See Also:
-
COLUMN_WEIGHTVALUE
- See Also:
-
COLUMNS
-
-
Constructor Details
-
VerboseCSVMeasureOutput
public VerboseCSVMeasureOutput(Measure measure, SimParameters simParameters, boolean isTerminalSimulation, int parametricStep) throws IOException Constructor of a NewCSVMeasureOutput object, using a file.- Parameters:
measure- the measure to be sent in outputsimParameters- the simulation parametersisTerminalSimulation- whether the simulation is terminalparametricStep- the current parametric step- 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
-