Record Class FactorRiskModel.Settings
java.lang.Object
java.lang.Record
com.quantfinlib.risk.FactorRiskModel.Settings
- Record Components:
factorHalfLife- EWMA half-life of the factor covariance (> 0)neweyWestLags- Newey-West lagsL(≥ 0)volatilityRegimeHalfLife- half-life of the bias statistic average (0 = no adjustment)specificHalfLife- EWMA half-life of specific variance (> 0)shrinkage- Bayesian shrinkage intensityq(≥ 0, 0 = none)sizeBuckets- number of capitalisation buckets for shrinkage (≥ 1)winsorLimit- clip of standardised styles, in standard deviations (> 0)
- Enclosing class:
FactorRiskModel
public static record FactorRiskModel.Settings(int factorHalfLife, int neweyWestLags, int volatilityRegimeHalfLife, int specificHalfLife, double shrinkage, int sizeBuckets, double winsorLimit)
extends Record
Estimation settings. Half-lives are in periods.
-
Constructor Summary
ConstructorsConstructorDescriptionSettings(int factorHalfLife, int neweyWestLags, int volatilityRegimeHalfLife, int specificHalfLife, double shrinkage, int sizeBuckets, double winsorLimit) Creates an instance of aSettingsrecord class. -
Method Summary
Modifier and TypeMethodDescriptionstatic FactorRiskModel.Settingsdefaults()Daily defaults close to the USE4 short-horizon choices: factor half-life 90, two Newey-West lags, regime half-life 42, specific half-life 90,q = 0.1, ten size buckets, clip at 3.final booleanIndicates whether some other object is "equal to" this one.intReturns the value of thefactorHalfLiferecord component.final inthashCode()Returns a hash code value for this object.intReturns the value of theneweyWestLagsrecord component.plain()The same settings without Newey-West, regime adjustment or shrinkage.doubleReturns the value of theshrinkagerecord component.intReturns the value of thesizeBucketsrecord component.intReturns the value of thespecificHalfLiferecord component.final StringtoString()Returns a string representation of this record class.intReturns the value of thevolatilityRegimeHalfLiferecord component.doubleReturns the value of thewinsorLimitrecord component.
-
Constructor Details
-
Settings
public Settings(int factorHalfLife, int neweyWestLags, int volatilityRegimeHalfLife, int specificHalfLife, double shrinkage, int sizeBuckets, double winsorLimit) Creates an instance of aSettingsrecord class.- Parameters:
factorHalfLife- the value for thefactorHalfLiferecord componentneweyWestLags- the value for theneweyWestLagsrecord componentvolatilityRegimeHalfLife- the value for thevolatilityRegimeHalfLiferecord componentspecificHalfLife- the value for thespecificHalfLiferecord componentshrinkage- the value for theshrinkagerecord componentsizeBuckets- the value for thesizeBucketsrecord componentwinsorLimit- the value for thewinsorLimitrecord component
-
-
Method Details
-
defaults
Daily defaults close to the USE4 short-horizon choices: factor half-life 90, two Newey-West lags, regime half-life 42, specific half-life 90,q = 0.1, ten size buckets, clip at 3. -
plain
The same settings without Newey-West, regime adjustment or shrinkage. -
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. -
factorHalfLife
public int factorHalfLife()Returns the value of thefactorHalfLiferecord component.- Returns:
- the value of the
factorHalfLiferecord component
-
neweyWestLags
public int neweyWestLags()Returns the value of theneweyWestLagsrecord component.- Returns:
- the value of the
neweyWestLagsrecord component
-
volatilityRegimeHalfLife
public int volatilityRegimeHalfLife()Returns the value of thevolatilityRegimeHalfLiferecord component.- Returns:
- the value of the
volatilityRegimeHalfLiferecord component
-
specificHalfLife
public int specificHalfLife()Returns the value of thespecificHalfLiferecord component.- Returns:
- the value of the
specificHalfLiferecord component
-
shrinkage
-
sizeBuckets
public int sizeBuckets()Returns the value of thesizeBucketsrecord component.- Returns:
- the value of the
sizeBucketsrecord component
-
winsorLimit
public double winsorLimit()Returns the value of thewinsorLimitrecord component.- Returns:
- the value of the
winsorLimitrecord component
-