Record Class VolatilityForecaster.Validation
java.lang.Object
java.lang.Record
com.quantfinlib.ml.VolatilityForecaster.Validation
- Enclosing class:
VolatilityForecaster
public static record VolatilityForecaster.Validation(int forecasts, double rmseModel, double rmseEwma, double rmseHar)
extends Record
Out-of-sample comparison: RMSE (per-period vol units) of the model and
of the two baselines over the same forecast dates.
-
Constructor Summary
ConstructorsConstructorDescriptionValidation(int forecasts, double rmseModel, double rmseEwma, double rmseHar) Creates an instance of aValidationrecord class. -
Method Summary
Modifier and TypeMethodDescriptionbooleanTrue when the model beats both baselines out of sample.final booleanIndicates whether some other object is "equal to" this one.intReturns the value of theforecastsrecord component.final inthashCode()Returns a hash code value for this object.doublermseEwma()Returns the value of thermseEwmarecord component.doublermseHar()Returns the value of thermseHarrecord component.doubleReturns the value of thermseModelrecord component.final StringtoString()Returns a string representation of this record class.
-
Constructor Details
-
Validation
public Validation(int forecasts, double rmseModel, double rmseEwma, double rmseHar) Creates an instance of aValidationrecord class.- Parameters:
forecasts- the value for theforecastsrecord componentrmseModel- the value for thermseModelrecord componentrmseEwma- the value for thermseEwmarecord componentrmseHar- the value for thermseHarrecord component
-
-
Method Details
-
beatsBaselines
public boolean beatsBaselines()True when the model beats both baselines out of sample. -
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. All components in this record class are compared with thecomparemethod from their corresponding wrapper classes. -
forecasts
public int forecasts()Returns the value of theforecastsrecord component.- Returns:
- the value of the
forecastsrecord component
-
rmseModel
public double rmseModel()Returns the value of thermseModelrecord component.- Returns:
- the value of the
rmseModelrecord component
-
rmseEwma
public double rmseEwma()Returns the value of thermseEwmarecord component.- Returns:
- the value of the
rmseEwmarecord component
-
rmseHar
public double rmseHar()Returns the value of thermseHarrecord component.- Returns:
- the value of the
rmseHarrecord component
-