Record Class VarBacktest.VarBacktestResult

java.lang.Object
java.lang.Record
com.quantfinlib.risk.VarBacktest.VarBacktestResult
Enclosing class:
VarBacktest

public static record VarBacktest.VarBacktestResult(int observations, int exceptions, double expectedExceptions, double exceptionRate, double kupiecStatistic, double kupiecPValue, double independenceStatistic, double independencePValue, double conditionalCoverageStatistic, double conditionalCoveragePValue) extends Record
  • Constructor Summary

    Constructors
    Constructor
    Description
    VarBacktestResult(int observations, int exceptions, double expectedExceptions, double exceptionRate, double kupiecStatistic, double kupiecPValue, double independenceStatistic, double independencePValue, double conditionalCoverageStatistic, double conditionalCoveragePValue)
    Creates an instance of a VarBacktestResult record class.
  • Method Summary

    Modifier and Type
    Method
    Description
    boolean
    calibrated(double significance)
    Exception frequency consistent with the confidence level?
    double
    Returns the value of the conditionalCoveragePValue record component.
    double
    Returns the value of the conditionalCoverageStatistic record component.
    final boolean
    Indicates whether some other object is "equal to" this one.
    double
    Returns the value of the exceptionRate record component.
    int
    Returns the value of the exceptions record component.
    double
    Returns the value of the expectedExceptions record component.
    final int
    Returns a hash code value for this object.
    double
    Returns the value of the independencePValue record component.
    double
    Returns the value of the independenceStatistic record component.
    boolean
    independent(double significance)
    Exceptions arrive independently (no crisis clustering)?
    double
    Returns the value of the kupiecPValue record component.
    double
    Returns the value of the kupiecStatistic record component.
    int
    Returns the value of the observations record component.
    boolean
    passes(double significance)
    Joint test: right rate AND independent.
    final String
    Returns a string representation of this record class.

    Methods inherited from class java.lang.Object

    clone, finalize, getClass, notify, notifyAll, wait, wait, wait
  • Constructor Details

    • VarBacktestResult

      public VarBacktestResult(int observations, int exceptions, double expectedExceptions, double exceptionRate, double kupiecStatistic, double kupiecPValue, double independenceStatistic, double independencePValue, double conditionalCoverageStatistic, double conditionalCoveragePValue)
      Creates an instance of a VarBacktestResult record class.
      Parameters:
      observations - the value for the observations record component
      exceptions - the value for the exceptions record component
      expectedExceptions - the value for the expectedExceptions record component
      exceptionRate - the value for the exceptionRate record component
      kupiecStatistic - the value for the kupiecStatistic record component
      kupiecPValue - the value for the kupiecPValue record component
      independenceStatistic - the value for the independenceStatistic record component
      independencePValue - the value for the independencePValue record component
      conditionalCoverageStatistic - the value for the conditionalCoverageStatistic record component
      conditionalCoveragePValue - the value for the conditionalCoveragePValue record component
  • Method Details

    • calibrated

      public boolean calibrated(double significance)
      Exception frequency consistent with the confidence level?
    • independent

      public boolean independent(double significance)
      Exceptions arrive independently (no crisis clustering)?
    • passes

      public boolean passes(double significance)
      Joint test: right rate AND independent.
    • 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.
    • observations

      public int observations()
      Returns the value of the observations record component.
      Returns:
      the value of the observations record component
    • exceptions

      public int exceptions()
      Returns the value of the exceptions record component.
      Returns:
      the value of the exceptions record component
    • expectedExceptions

      public double expectedExceptions()
      Returns the value of the expectedExceptions record component.
      Returns:
      the value of the expectedExceptions record component
    • exceptionRate

      public double exceptionRate()
      Returns the value of the exceptionRate record component.
      Returns:
      the value of the exceptionRate record component
    • kupiecStatistic

      public double kupiecStatistic()
      Returns the value of the kupiecStatistic record component.
      Returns:
      the value of the kupiecStatistic record component
    • kupiecPValue

      public double kupiecPValue()
      Returns the value of the kupiecPValue record component.
      Returns:
      the value of the kupiecPValue record component
    • independenceStatistic

      public double independenceStatistic()
      Returns the value of the independenceStatistic record component.
      Returns:
      the value of the independenceStatistic record component
    • independencePValue

      public double independencePValue()
      Returns the value of the independencePValue record component.
      Returns:
      the value of the independencePValue record component
    • conditionalCoverageStatistic

      public double conditionalCoverageStatistic()
      Returns the value of the conditionalCoverageStatistic record component.
      Returns:
      the value of the conditionalCoverageStatistic record component
    • conditionalCoveragePValue

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