Record Class AlphaRiskModels.Spec
java.lang.Object
java.lang.Record
com.quantfinlib.alpha.AlphaRiskModels.Spec
- Record Components:
window- estimation periods (≥ 2)momentumLookback- momentum lookback in barsvolLookback- low-volatility lookback in barscapWindow- bars of dollar volume for the size proxymodel- factor risk model settings
- Enclosing class:
AlphaRiskModels
public static record AlphaRiskModels.Spec(int window, int momentumLookback, int volLookback, int capWindow, FactorRiskModel.Settings model)
extends Record
Risk model specification.
-
Constructor Summary
ConstructorsConstructorDescriptionSpec(int window, int momentumLookback, int volLookback, int capWindow, FactorRiskModel.Settings model) Creates an instance of aSpecrecord class. -
Method Summary
Modifier and TypeMethodDescriptionintReturns the value of thecapWindowrecord component.static AlphaRiskModels.Specdefaults()120-period window, 60-bar momentum and volatility, 20-bar size proxy, default model.final booleanIndicates whether some other object is "equal to" this one.intFirst bar at which a model can be built.final inthashCode()Returns a hash code value for this object.model()Returns the value of themodelrecord component.intReturns the value of themomentumLookbackrecord component.final StringtoString()Returns a string representation of this record class.intReturns the value of thevolLookbackrecord component.intwindow()Returns the value of thewindowrecord component.
-
Constructor Details
-
Spec
public Spec(int window, int momentumLookback, int volLookback, int capWindow, FactorRiskModel.Settings model) Creates an instance of aSpecrecord class.- Parameters:
window- the value for thewindowrecord componentmomentumLookback- the value for themomentumLookbackrecord componentvolLookback- the value for thevolLookbackrecord componentcapWindow- the value for thecapWindowrecord componentmodel- the value for themodelrecord component
-
-
Method Details
-
defaults
120-period window, 60-bar momentum and volatility, 20-bar size proxy, default model. -
firstIndex
public int firstIndex()First bar at which a model can be built. -
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. -
window
-
momentumLookback
public int momentumLookback()Returns the value of themomentumLookbackrecord component.- Returns:
- the value of the
momentumLookbackrecord component
-
volLookback
public int volLookback()Returns the value of thevolLookbackrecord component.- Returns:
- the value of the
volLookbackrecord component
-
capWindow
-
model
-