Package jline.api.mam
Class PhaseTrace
java.lang.Object
jline.api.mam.PhaseTrace
Ordered list of (phase, holding time) sojourns, 0-based phases.
The sojourns of one draw sum to the drawn total (up to floating-point
summation order: the samplers accumulate the same holding times into the
total in the same order, so total() equals the returned sample
exactly). exitPhase() is the phase the process enters at the
absorbing (D1) transition, i.e. the phase the NEXT draw of a stateful sampler
starts from; it is -1 when the draw did not record one.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidadd(int ph, double holding) Appends one sojourn of lengthholdingin 0-basedph.voidclear()Empties the trace, keeping its storage.copy()Deep copy, so a sampler can reuse its scratch trace.intdoubleholding(int i) intphase(int i) voidsetExitPhase(int ph) Sets the phase entered by the absorbing transition.intsize()doubletotal()Sum of the recorded holding times, accumulated in recording order.
-
Constructor Details
-
PhaseTrace
public PhaseTrace()
-
-
Method Details
-
clear
public void clear()Empties the trace, keeping its storage. -
add
public void add(int ph, double holding) Appends one sojourn of lengthholdingin 0-basedph. -
setExitPhase
public void setExitPhase(int ph) Sets the phase entered by the absorbing transition. -
exitPhase
public int exitPhase() -
size
public int size() -
phase
public int phase(int i) -
holding
public double holding(int i) -
total
public double total()Sum of the recorded holding times, accumulated in recording order. -
copy
Deep copy, so a sampler can reuse its scratch trace.
-