Package jline.api.mam

Class PhaseTrace

java.lang.Object
jline.api.mam.PhaseTrace

public final class PhaseTrace extends Object
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
    Constructor
    Description
     
  • Method Summary

    Modifier and Type
    Method
    Description
    void
    add(int ph, double holding)
    Appends one sojourn of length holding in 0-based ph.
    void
    Empties the trace, keeping its storage.
    Deep copy, so a sampler can reuse its scratch trace.
    int
     
    double
    holding(int i)
     
    int
    phase(int i)
     
    void
    setExitPhase(int ph)
    Sets the phase entered by the absorbing transition.
    int
     
    double
    Sum of the recorded holding times, accumulated in recording order.

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • 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 length holding in 0-based ph.
    • 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

      public PhaseTrace copy()
      Deep copy, so a sampler can reuse its scratch trace.