Record Class StressTester.ReverseStress
java.lang.Object
java.lang.Record
com.quantfinlib.risk.StressTester.ReverseStress
- Enclosing class:
StressTester
public static record StressTester.ReverseStress(double[] shocks, double mahalanobisSigmas)
extends Record
The reverse-stress answer: the most-probable shock vector and its distance.
-
Constructor Summary
ConstructorsConstructorDescriptionReverseStress(double[] shocks, double mahalanobisSigmas) Creates an instance of aReverseStressrecord class. -
Method Summary
Modifier and TypeMethodDescriptionfinal booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.doubleReturns the value of themahalanobisSigmasrecord component.double[]shocks()Returns the value of theshocksrecord component.final StringtoString()Returns a string representation of this record class.
-
Constructor Details
-
ReverseStress
public ReverseStress(double[] shocks, double mahalanobisSigmas) Creates an instance of aReverseStressrecord class.- Parameters:
shocks- the value for theshocksrecord componentmahalanobisSigmas- the value for themahalanobisSigmasrecord component
-
-
Method Details
-
toString
-
hashCode
-
equals
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. Reference components are compared withObjects::equals(Object,Object); primitive components are compared with thecomparemethod from their corresponding wrapper classes. -
shocks
public double[] shocks()Returns the value of theshocksrecord component.- Returns:
- the value of the
shocksrecord component
-
mahalanobisSigmas
public double mahalanobisSigmas()Returns the value of themahalanobisSigmasrecord component.- Returns:
- the value of the
mahalanobisSigmasrecord component
-