Negative Skewness Constraints
PortfolioOptimisers.get_chol_or_V_pm Function
get_chol_or_V_pm(model::Model, pr::HighOrderPrior) -> AnyRetrieve or compute and cache the square-root matrix of the co-skewness matrix V.
If model does not yet contain GV, attempts a Cholesky factorisation of pr.V and falls back to sqrt(pr.V) for positive-semidefinite matrices. Stores the result as model[:GV].
Arguments
model::JuMP.Model: The JuMP optimisation model.pr::HighOrderPrior: High-order prior containingV.
Returns
GV::Matrix: Square-root factor of the co-skewness matrix.
Related
sourcePortfolioOptimisers.set_negative_skewness_risk! Function
set_negative_skewness_risk!(
model::Model,
r::NegativeSkewness{<:Any, <:Any, <:Any, <:Any, <:SOCRiskExpr},
opt::RiskJuMPOptimisationEstimator,
nskew_risk::AbstractJuMPScalar,
key::Symbol,
args...
) -> AbstractJuMPScalarFinalise the negative-skewness risk expression and apply bounds according to the formulation.
The SOCRiskExpr overload passes the SOC variable directly to set_risk_bounds_and_expression!. The SquaredSOCRiskExpr overload squares it. The QuadRiskExpr overload encodes skewness as the quadratic form w' * V * w.
Arguments
model::JuMP.Model: The JuMP optimisation model.r::NegativeSkewness: Negative-skewness risk measure instance.opt::RiskJuMPOptimisationEstimator: Risk-based optimisation estimator.nskew_risk: SOC variable for negative-skewness risk.key::Symbol: Symbol used to name constraints or expressions in the model.V::MatNum: Co-skewness matrix (used only by the Quad overload).
Returns
- The negative-skewness risk JuMP expression.
Related
sourcePortfolioOptimisers.set_risk_constraints! Method
set_risk_constraints!(
model::Model,
i,
r::NegativeSkewness,
opt::RiskJuMPOptimisationEstimator,
pr::HighOrderPrior,
args...;
kwargs...
) -> AnyAdd negative-skewness risk constraints to model.
The HighOrderPrior overload selects the co-skewness matrix (from r.V or pr.V), creates a scalar variable, adds the SOC constraint [sc * nskew_risk; sc * G * w] in SOC, and dispatches to set_negative_skewness_risk! for bounding. The LowOrderPrior overload unconditionally throws an ArgumentError.
Arguments
model::JuMP.Model: The JuMP optimisation model.i: Constraint index for unique variable and constraint naming.r::NegativeSkewness: Negative-skewness risk measure instance.opt::RiskJuMPOptimisationEstimator: Risk-based optimisation estimator.pr::HighOrderPrior: High-order prior containingV.
Returns
nothing.
Related
sourcePortfolioOptimisers.set_risk_constraints! Method
set_risk_constraints!(
::Model,
,
::NegativeSkewness,
::RiskJuMPOptimisationEstimator,
pr::LowOrderPrior,
args...;
kwargs...
)Throw an ArgumentError indicating that NegativeSkewness requires a HighOrderPrior.
This fall-through overload is triggered when a LowOrderPrior is passed and always raises an error.
Arguments
r::NegativeSkewness: The negative skewness risk measure (unused).pr::LowOrderPrior: A low-order prior (not compatible with negative skewness).
Returns
- Does not return; always throws
ArgumentError.
Related
source