Record Class MonteCarloTradeShuffle.Result

java.lang.Object
java.lang.Record
com.quantfinlib.backtest.validation.MonteCarloTradeShuffle.Result
Record Components:
medianMaxDrawdown - 50th-percentile max drawdown across shuffles (P&L units)
p95MaxDrawdown - 95th-percentile max drawdown — the plan-for number
p99MaxDrawdown - 99th-percentile max drawdown — the tail
medianTerminalPnl - 50th-percentile terminal cumulative P&L
probLoss - fraction of shuffles ending below zero
actualMaxDrawdown - the observed (unshuffled) path's max drawdown
actualDrawdownPct - where the observed drawdown sits in the shuffle distribution (0..1); high = the real order was UNUSUALLY painful, a hint of loss clustering
Enclosing class:
MonteCarloTradeShuffle

public static record MonteCarloTradeShuffle.Result(double medianMaxDrawdown, double p95MaxDrawdown, double p99MaxDrawdown, double medianTerminalPnl, double probLoss, double actualMaxDrawdown, double actualDrawdownPct) extends Record
  • Constructor Details

    • Result

      public Result(double medianMaxDrawdown, double p95MaxDrawdown, double p99MaxDrawdown, double medianTerminalPnl, double probLoss, double actualMaxDrawdown, double actualDrawdownPct)
      Creates an instance of a Result record class.
      Parameters:
      medianMaxDrawdown - the value for the medianMaxDrawdown record component
      p95MaxDrawdown - the value for the p95MaxDrawdown record component
      p99MaxDrawdown - the value for the p99MaxDrawdown record component
      medianTerminalPnl - the value for the medianTerminalPnl record component
      probLoss - the value for the probLoss record component
      actualMaxDrawdown - the value for the actualMaxDrawdown record component
      actualDrawdownPct - the value for the actualDrawdownPct record component
  • Method Details

    • toString

      public final String toString()
      Returns a string representation of this record class. The representation contains the name of the class, followed by the name and value of each of the record components.
      Specified by:
      toString in class Record
      Returns:
      a string representation of this object
    • hashCode

      public final int hashCode()
      Returns a hash code value for this object. The value is derived from the hash code of each of the record components.
      Specified by:
      hashCode in class Record
      Returns:
      a hash code value for this object
    • equals

      public final boolean equals(Object o)
      Indicates whether some other object is "equal to" this one. The objects are equal if the other object is of the same class and if all the record components are equal. All components in this record class are compared with the compare method from their corresponding wrapper classes.
      Specified by:
      equals in class Record
      Parameters:
      o - the object with which to compare
      Returns:
      true if this object is the same as the o argument; false otherwise.
    • medianMaxDrawdown

      public double medianMaxDrawdown()
      Returns the value of the medianMaxDrawdown record component.
      Returns:
      the value of the medianMaxDrawdown record component
    • p95MaxDrawdown

      public double p95MaxDrawdown()
      Returns the value of the p95MaxDrawdown record component.
      Returns:
      the value of the p95MaxDrawdown record component
    • p99MaxDrawdown

      public double p99MaxDrawdown()
      Returns the value of the p99MaxDrawdown record component.
      Returns:
      the value of the p99MaxDrawdown record component
    • medianTerminalPnl

      public double medianTerminalPnl()
      Returns the value of the medianTerminalPnl record component.
      Returns:
      the value of the medianTerminalPnl record component
    • probLoss

      public double probLoss()
      Returns the value of the probLoss record component.
      Returns:
      the value of the probLoss record component
    • actualMaxDrawdown

      public double actualMaxDrawdown()
      Returns the value of the actualMaxDrawdown record component.
      Returns:
      the value of the actualMaxDrawdown record component
    • actualDrawdownPct

      public double actualDrawdownPct()
      Returns the value of the actualDrawdownPct record component.
      Returns:
      the value of the actualDrawdownPct record component