public abstract class ProbabilityStatistic extends Statistic implements Printable, WeightedSampleCollector<java.lang.Boolean,java.lang.Long>
ProbabilityStatistic
serves to record the results of
Bernoulli trials, which are random experiments with only two possible results
(e.g., failure probability in a queue with limited capacity).
update(long, boolean)
records the number of trials that have the
same result (true
or false
). getBatchProbability()
)
getMean()
) including a
confidence interval (getConfidenceInterval()
)
ProbabilityStatistic
, have been implemented in the
derived class
StdProbabilityStatistic
. An object
of this class can be created with the
createProbabilityStatistic()
method from
StatisticManager
and deleted with
deleteProbabilityStatistic()
.
For printing the results it defines the following keywords:
sampleIndex, simNode, traceWriter
Constructor and Description |
---|
ProbabilityStatistic(SimNode ownNode) |
Modifier and Type | Method and Description |
---|---|
abstract double |
getBatchProbability() |
abstract double |
getConfidenceInterval() |
abstract double |
getMean() |
void |
printResults(ResultType type,
PrintResultWriter writer) |
void |
update(java.lang.Boolean special) |
void |
update(java.lang.Boolean sample,
java.lang.Long weight) |
abstract void |
update(long number,
boolean special) |
addResultTag, addResultTag, computeMeasures, disableTracing, enableTracing, handleInitSimulation, handleStartBatch, handleStartTransientPhase, handleStopBatch, handleStopTransientPhase, printComments, resetBatchStatistic, resetStatistic, update, writeTraceEntry
public ProbabilityStatistic(SimNode ownNode)
public void printResults(ResultType type, PrintResultWriter writer) throws PrintException
printResults
in interface Printable
PrintException
public abstract void update(long number, boolean special)
public void update(java.lang.Boolean special)
update
in interface UnweightedSampleCollector<java.lang.Boolean>
public void update(java.lang.Boolean sample, java.lang.Long weight)
update
in interface WeightedSampleCollector<java.lang.Boolean,java.lang.Long>
public abstract double getMean()
public abstract double getBatchProbability()
public abstract double getConfidenceInterval()