Ordered Weights Array
Certain risk measures can be expressed as ordered weights arrays [107, 108]. It is also possible to express higher Linear moments (l-moments) as linear combinations of ordered weights arrays [109].
These types and functions implement the various existing formulations and risk measures representable by ordered weights arrays.
PortfolioOptimisers.AbstractOrderedWeightsArrayFunction — Type
abstract type AbstractOrderedWeightsArrayFunction <: AbstractEstimatorAbstract supertype for callable OWA weight function estimators.
All concrete subtypes implementing callable OWA weight functions should subtype AbstractOrderedWeightsArrayFunction.
Interfaces
In order to implement a new callable OWA weight function that works seamlessly with the library, subtype AbstractOrderedWeightsArrayFunction, ensuring that the structure contains all necessary parameters, and implement the following method:
Callable interface
(r::ConcreteType)(T::Integer) -> VecNum: Computes and returns the OWA weight vector forTobservations.
Arguments
r: Callable OWA weight function instance.T::Integer: Number of observations.
Returns
w::VecNum: OWA weight vector of lengthT.
Examples
julia> struct MyOWAFunction <: PortfolioOptimisers.AbstractOrderedWeightsArrayFunction endjulia> function (r::MyOWAFunction)(T::Integer) return fill(inv(T), T) endjulia> MyOWAFunction()(4)4-element Vector{Float64}: 0.25 0.25 0.25 0.25Related
References
- [110] W. Ogryczak and T. Śliwiński. On solving linear programs with the ordered weighted averaging objective. European Journal of Operational Research 148, 80–91 (2003).
- [107] D. Cajas. OWA portfolio optimization: A disciplined convex programming framework. Available at SSRN 3988927 (2021).
- [5] D. Cajas. Advanced Portfolio Optimization: A Cutting-edge Quantitative Approach (Springer Nature Switzerland, 2025). Section 7.1.5.
PortfolioOptimisers.ExponentialConeEntropy — Type
struct ExponentialConeEntropy <: EntropyFormulationEntropy formulation for MaximumEntropy OWA that uses the exponential cone entropy constraint in JuMP.
Related
References
- [109] D. Cajas. Higher order moment portfolio optimization with L-moments. Available at SSRN 4393155 (2023).
PortfolioOptimisers.RelativeEntropy — Type
struct RelativeEntropy <: EntropyFormulationEntropy formulation for MaximumEntropy OWA that uses the relative entropy cone constraint in JuMP. This is the default entropy formulation.
Related
References
- [109] D. Cajas. Higher order moment portfolio optimization with L-moments. Available at SSRN 4393155 (2023).
PortfolioOptimisers.MaximumEntropy — Type
struct MaximumEntropy{__T_alg} <: AbstractOrderedWeightsArrayAlgorithmRepresents the Maximum Entropy algorithm for Ordered Weights Array (OWA) estimation.
The Maximum Entropy algorithm seeks the OWA weights that maximize entropy, resulting in the most "uninformative" or uniform distribution of weights subject to the imposed constraints.
\[\begin{align} \underset{\boldsymbol{\phi},\, \boldsymbol{\psi}}{\max} -\sum\limits_{t=1}^{T}\psi_{t} \log\left(\psi_{t}\right)\\ \text{s.t.} \quad & \left(\psi_{i},\,\theta_{i}\right) \in \mathcal{K}_{noc} \quad \forall i = 1, \ldots,\, T \\ & \sum\limits_{t=1}^T \psi_{t} = 1 \\ & \sum\limits_{k=1}^K \phi_{k} = 1 \\ & \boldsymbol{\phi} \leq \phi_{\text{max}} \\ & \boldsymbol{\phi} \geq 0 \\ & \phi_{k+1} \leq \phi_{k} \quad \forall k = 1, \ldots,\, K-1 \\ & \boldsymbol{w}_{k} = \dfrac{1}{k} \binom{T}{k}^{-1} \sum\limits_{i=0}^{k-1} (-1)^{i} \binom{k-1}{i} \binom{t-1}{k-1-i} \binom{T-t}{i} \quad \forall t = 1,\ldots,\, T \\ & \mathbf{w} = \left[(-1)^k\boldsymbol{w}_{k} \quad \forall k = 2,\ldots,\, K\right] \\ & \boldsymbol{\theta} = \mathbf{w} \boldsymbol{\phi} \\ & \theta_{t+1} \geq \theta_{t} \quad \forall t = 1, \ldots,\, T-1 \\ \end{align}\]
Where:
- $\mathcal{K}_{\text{noc}} \coloneqq \left\{\left(t,\,x\right) \in \mathbb{R}^n : t \geq \lVert x \rVert_{1} = \sum\limits_{i} \lvert x_{i} \rvert\right\}$: Is the norm one cone, which bounds each entry of $\boldsymbol{\psi}$ from below by the absolute value of the matching entry of $\boldsymbol{\theta}$.
- $\boldsymbol{\psi}$: Is the
T × 1entropy variable. It lies on the unit simplex, so the objective is the Shannon entropy of a probability vector that dominates $\lvert \boldsymbol{\theta} \rvert$ entry by entry. - $\phi_{k}$: Is the risk aversion coefficient for the
k-th order moment. - $\phi_{\text{max}}$: Is the maximum risk aversion coefficient.
- $T$: Is the total number of observations.
- $\boldsymbol{w}_{k}$: Is the
T × 1OWA weights vector for thek-th order moment. - $\mathbf{w}$: Is the
T × Kmatrix of OWA weights for all order moments where each columnkcorresponds to weights of thek-th order moment, each row corresponds to the weights for thet-th observation. - $\boldsymbol{\theta}$: Is the final
T × 1OWA weights vector after enforcing non-decreasing monotonicity and incorporating the user-defined risk aversion.
Fields
alg: Risk measure optimisation formulation algorithm.
Constructors
MaximumEntropy(; alg::EntropyFormulation = RelativeEntropy(),) -> MaximumEntropyKeywords correspond to the struct's fields.
Details
The MaximumEntropy algorithm can be configured to use different entropy formulations via the alg field. The default is RelativeEntropy, but other formulations such as ExponentialConeEntropy can also be used.
alg selects the conic encoding of the entropy term, not the problem that is solved. RelativeEntropy writes it as one JuMP.MOI.RelativeEntropyCone of dimension 2T + 1, and ExponentialConeEntropy writes it as T separate JuMP.MOI.ExponentialCone constraints. Both attain the same OWA weights to solver tolerance.
Examples
julia> MaximumEntropy()MaximumEntropy alg ┴ RelativeEntropy()Related
References
- [109] D. Cajas. Higher order moment portfolio optimization with L-moments. Available at SSRN 4393155 (2023).
PortfolioOptimisers.MinimumSquaredDistance — Type
struct MinimumSquaredDistance{__T_alg} <: SquaredOrderedWeightsArrayAlgorithm{__T_alg}Represents the Minimum Squared Distance algorithm for Ordered Weights Array (OWA) estimation.
The Minimum Squared Distance algorithm finds OWA weights that minimize the squared distance between adjacent entries in the array, subject to the OWA constraints. This approach promotes smoothness in the resulting weights.
\[\begin{align} \underset{\boldsymbol{\theta}}{\min} \sum\limits_{t=1}^{T-1}\left(\boldsymbol{\theta}_{t+1} - \boldsymbol{\theta}_{t} \right)^2 \\ \text{s.t.} \quad & \sum\limits_{k=1}^K \phi_{k} = 1 \\ & \boldsymbol{\phi} \leq \phi_{\text{max}} \\ & \boldsymbol{\phi} \geq 0 \\ & \phi_{k+1} \leq \phi_{k} \quad \forall k = 1, \ldots,\, K-1 \\ & \boldsymbol{w}_{k} = \dfrac{1}{k} \binom{T}{k}^{-1} \sum\limits_{i=0}^{k-1} (-1)^{i} \binom{k-1}{i} \binom{t-1}{k-1-i} \binom{T-t}{i} \quad \forall t = 1,\ldots,\, T \\ & \mathbf{w} = \left[(-1)^k\boldsymbol{w}_{k} \quad \forall k = 2,\ldots,\, K\right] \\ & \boldsymbol{\theta} = \mathbf{w} \boldsymbol{\phi} \\ & \theta_{t+1} \geq \theta_{t} \quad \forall t = 1, \ldots,\, T-1 \\ \end{align}\]
Where:
- $\phi_{k}$: Is the risk aversion coefficient for the
k-th order moment. - $\phi_{\text{max}}$: Is the maximum risk aversion coefficient.
- $T$: Is the total number of observations.
- $\boldsymbol{w}_{k}$: Is the
T × 1OWA weights vector for thek-th order moment. - $\mathbf{w}$: Is the
T × Kmatrix of OWA weights for all order moments where each columnkcorresponds to weights of thek-th order moment, each row corresponds to the weights for thet-th observation. - $\boldsymbol{\theta}$: Is the final
T × 1OWA weights vector after enforcing non-decreasing monotonicity and incorporating the user-defined risk aversion.
Fields
alg: Risk measure optimisation formulation algorithm.
Constructors
MinimumSquaredDistance(; alg::UnionAllSOCRiskExpr = SOCRiskExpr(),) -> MinimumSquaredDistanceKeywords correspond to the struct's fields.
Examples
julia> MinimumSquaredDistance()MinimumSquaredDistance alg ┴ SOCRiskExpr()Details
The MinimumSquaredDistance algorithm can be configured to use different second-order cone risk expressions via the alg field. The default is SOCRiskExpr, but other formulations such as SquaredSOCRiskExpr or RSOCRiskExpr can also be used.
alg selects the conic encoding of the objective, not the problem that is solved. SOCRiskExpr minimises $\lVert \boldsymbol{\theta}_{2:T} - \boldsymbol{\theta}_{1:T-1} \rVert_{2}$, while SquaredSOCRiskExpr and RSOCRiskExpr minimise its square. The square root is strictly increasing, so all three share the same minimiser and return the same OWA weights to solver tolerance. This differs from SecondMomentFormulation, where alg changes the units of the reported risk.
Related
References
- [109] D. Cajas. Higher order moment portfolio optimization with L-moments. Available at SSRN 4393155 (2023).
PortfolioOptimisers.MinimumSumSquares — Type
struct MinimumSumSquares{__T_alg} <: SquaredOrderedWeightsArrayAlgorithm{__T_alg}Represents the Minimum Sum of Squares algorithm for Ordered Weights Array (OWA) estimation.
The Minimum Sum of Squares algorithm minimizes the sum of squared OWA weights, subject to the OWA constraints. This is a ridge penalty on the weight vector, so it spreads the weight mass rather than concentrating it. Use it when the OWA weights should stay small in magnitude, and use MinimumSquaredDistance when they should instead vary smoothly from one order statistic to the next.
\[\begin{align} \underset{\boldsymbol{\theta}}{\min} \sum\limits_{t=1}^{T} \boldsymbol{\theta}_{t}^2 \\ \text{s.t.} \quad & \sum\limits_{k=1}^K \phi_{k} = 1 \\ & \boldsymbol{\phi} \leq \phi_{\text{max}} \\ & \boldsymbol{\phi} \geq 0 \\ & \phi_{k+1} \leq \phi_{k} \quad \forall k = 1, \ldots,\, K-1 \\ & \boldsymbol{w}_{k} = \dfrac{1}{k} \binom{T}{k}^{-1} \sum\limits_{i=0}^{k-1} (-1)^{i} \binom{k-1}{i} \binom{t-1}{k-1-i} \binom{T-t}{i} \quad \forall t = 1,\ldots,\, T \\ & \mathbf{w} = \left[(-1)^k\boldsymbol{w}_{k} \quad \forall k = 2,\ldots,\, K\right] \\ & \boldsymbol{\theta} = \mathbf{w} \boldsymbol{\phi} \\ & \theta_{t+1} \geq \theta_{t} \quad \forall t = 1, \ldots,\, T-1 \\ \end{align}\]
Where:
- $\phi_{k}$: Is the risk aversion coefficient for the
k-th order moment. - $\phi_{\text{max}}$: Is the maximum risk aversion coefficient.
- $T$: Is the total number of observations.
- $\boldsymbol{w}_{k}$: Is the
T × 1OWA weights vector for thek-th order moment. - $\mathbf{w}$: Is the
T × Kmatrix of OWA weights for all order moments where each columnkcorresponds to weights of thek-th order moment, each row corresponds to the weights for thet-th observation. - $\boldsymbol{\theta}$: Is the final
T × 1OWA weights vector after enforcing non-decreasing monotonicity and incorporating the user-defined risk aversion.
Fields
alg: Risk measure optimisation formulation algorithm.
Constructors
MinimumSumSquares(; alg::UnionAllSOCRiskExpr = SOCRiskExpr(),) -> MinimumSumSquaresKeywords correspond to the struct's fields.
Examples
julia> MinimumSumSquares()MinimumSumSquares alg ┴ SOCRiskExpr()Details
The MinimumSumSquares algorithm can be configured to use different second-order cone risk expressions via the alg field. The default is SOCRiskExpr, but other formulations such as SquaredSOCRiskExpr or RSOCRiskExpr can also be used.
alg selects the conic encoding of the objective, not the problem that is solved. SOCRiskExpr minimises $\lVert \boldsymbol{\theta} \rVert_{2}$, while SquaredSOCRiskExpr and RSOCRiskExpr minimise its square. The square root is strictly increasing, so all three share the same minimiser and return the same OWA weights to solver tolerance. This differs from SecondMomentFormulation, where alg changes the units of the reported risk.
Related
References
- [109] D. Cajas. Higher order moment portfolio optimization with L-moments. Available at SSRN 4393155 (2023).
PortfolioOptimisers.NormalisedConstantRelativeRiskAversion — Type
struct NormalisedConstantRelativeRiskAversion{__T_g} <: AbstractOrderedWeightsArrayEstimatorEstimator type for normalised constant relative risk aversion (CRRA) OWA weights.
This struct represents an estimator for Ordered Weights Array (OWA) weights based on a normalised constant relative risk aversion parameter g. The CRRA approach generates OWA weights that interpolate between risk-neutral and risk-averse profiles, controlled by the parameter g.
\[\begin{align} \phi_{1} &\coloneqq 1 \\ \boldsymbol{\phi} &= \phi_{k-1} \dfrac{\gamma + k - 2}{k!} (k-1)! \quad \forall k = 2,\ldots,\, K \\ \sum\limits_{k=2}^K \phi_{k} &= 1 \\ \boldsymbol{w}_{k} &= \dfrac{1}{k} \binom{T}{k}^{-1} \sum\limits_{i=0}^{k-1} (-1)^{i} \binom{k-1}{i} \binom{t-1}{k-1-i} \binom{T-t}{i} \quad \forall t = 1,\ldots,\, T \\ \mathbf{w} &= \left[(-1)^k\boldsymbol{w}_{k} \quad \forall k = 2,\ldots,\, K\right] \\ \boldsymbol{\vartheta} &= \mathbf{w} \boldsymbol{\phi} \\ \theta_{i} &= \max \left(\vartheta_{j} \quad \forall j = 1, \ldots,\, i\right) \quad \forall i = 1,\ldots,\, T \end{align}\]
Where:
- $\phi_{k}$: Is the risk aversion coefficient for the
k-th order moment. - $\gamma$: Is the risk aversion parameter
g. - $T$: Is the total number of observations.
- $\boldsymbol{w}_{k}$: Is the
T × 1OWA weights vector for thek-th order moment. - $\mathbf{w}$: Is the
T × Kmatrix of OWA weights for all order moments where each columnkcorresponds to weights of thek-th order moment, each row corresponds to the weights for thet-th observation. - $\boldsymbol{\vartheta}$: Is the intermediate
T × 1OWA weights vector incorporating the user-defined risk aversion before enforcing non-decreasing monotonicity. - $\boldsymbol{\theta}$: Is the final
T × 1OWA weights vector incorporating the user-defined risk aversion after enforcing non-decreasing monotonicity.
Fields
g: Risk aversion parameter.
Constructors
NormalisedConstantRelativeRiskAversion(; g::Number = 0.5,) -> NormalisedConstantRelativeRiskAversionKeywords correspond to the struct's fields.
Validation
0 < g < 1.
Examples
julia> NormalisedConstantRelativeRiskAversion()NormalisedConstantRelativeRiskAversion g ┴ Float64: 0.5Related
References
- [109] D. Cajas. Higher order moment portfolio optimization with L-moments. Available at SSRN 4393155 (2023).
PortfolioOptimisers.LinearMoment — Type
struct LinearMoment{__T_method, __T_k} <: AbstractOrderedWeightsArrayFunctionCallable estimator that generates OWA linear moment convex risk measure (CRM) weights for a given number of observations.
When called as lm(T), returns the OWA weight vector produced by owa_l_moment_crm using the configured method and moment order k.
Fields
method: OWA weight estimation method.
k: L-moment order.
Constructors
LinearMoment(; method::AbstractOrderedWeightsArrayEstimator = NormalisedConstantRelativeRiskAversion(), k::Integer = 2) -> LinearMomentKeywords correspond to the struct's fields.
Validation
k >= 2.
Examples
julia> LinearMoment()LinearMoment method ┼ NormalisedConstantRelativeRiskAversion │ g ┴ Float64: 0.5 k ┴ Int64: 2Related
AbstractOrderedWeightsArrayEstimatorNormalisedConstantRelativeRiskAversionOWAJuMPowa_l_moment_crmOWA_Func_VecNum
References
PortfolioOptimisers.OrderedWeightsArrayConditionalValueatRisk — Type
struct OrderedWeightsArrayConditionalValueatRisk{__T_alpha} <: AbstractOrderedWeightsArrayFunctionCallable OWA weight estimator for the Conditional Value at Risk (CVaR) risk measure.
When called as r(T), returns the OWA weight vector for CVaR at confidence level alpha for T observations.
Fields
alpha: Quantile level for the lower tail. The bound isNum_SigCal, so the slot takes the level itself, anAbstractSignificanceCalibrationAlgorithmthat computes it from the prior result, or a plain function of the same five arguments.
Constructors
OrderedWeightsArrayConditionalValueatRisk(; alpha::Num_SigCal = 0.05) -> OrderedWeightsArrayConditionalValueatRiskKeywords correspond to the struct's fields.
Validation
0 < alpha < 1.
Examples
julia> OrderedWeightsArrayConditionalValueatRisk()OrderedWeightsArrayConditionalValueatRisk alpha ┴ Float64: 0.05Related
References
- [103] R. T. Rockafellar and S. Uryasev. Optimization of conditional value-at-risk. Journal of Risk 2, 21–41 (2000).
- [107] D. Cajas. OWA portfolio optimization: A disciplined convex programming framework. Available at SSRN 3988927 (2021).
- [5] D. Cajas. Advanced Portfolio Optimization: A Cutting-edge Quantitative Approach (Springer Nature Switzerland, 2025). Section 7.2.2.4.
PortfolioOptimisers.OrderedWeightsArrayTailGini — Type
struct OrderedWeightsArrayTailGini{__T_alpha_i, __T_alpha, __T_a_sim} <: AbstractOrderedWeightsArrayFunctionCallable OWA weight estimator for the tail Gini risk measure.
When called as r(T), returns the OWA weight vector approximating the tail Gini measure by integrating over CVaR levels from alpha_i to alpha using a_sim points.
Fields
alpha_i: Lower integration bound for the tail Gini approximation.
alpha: Quantile level for the lower tail. The bound isNum_SigCal, so the slot takes the level itself, anAbstractSignificanceCalibrationAlgorithmthat computes it from the prior result, or a plain function of the same five arguments.
a_sim: Number of integration points for the tail Gini approximation.
Constructors
OrderedWeightsArrayTailGini(; alpha_i::Number = 1e-4, alpha::Num_SigCal = 0.05, a_sim::Integer = 100) -> OrderedWeightsArrayTailGiniKeywords correspond to the struct's fields.
Validation
0 < alpha_i < alpha < 1, checked whenalphais a number. Whenalphaholds a Calibration Rule only0 < alpha_i < 1is checked here, and the joint bound is checked when the rebuild runs at fold time. A rule that returns a value at or below the statedalpha_iis refused there, and this joint bound is the whole of the ordering validation.a_sim > 0.
Examples
julia> OrderedWeightsArrayTailGini()OrderedWeightsArrayTailGini alpha_i ┼ Float64: 0.0001 alpha ┼ Float64: 0.05 a_sim ┴ Int64: 100Related
References
- [111] W. Ogryczak and A. Ruszczyński. Dual stochastic dominance and quantile risk measures. International Transactions in Operational Research 9, 661–680 (2002).
- [107] D. Cajas. OWA portfolio optimization: A disciplined convex programming framework. Available at SSRN 3988927 (2021).
- [108] D. Cajas. Efficient Gini Mean Difference and Tail Gini Portfolio Optimization based on P-Norms. Available at SSRN 4711326 (2024).
- [5] D. Cajas. Advanced Portfolio Optimization: A Cutting-edge Quantitative Approach (Springer Nature Switzerland, 2025). Section 7.2.2.5.
PortfolioOptimisers.OrderedWeightsArrayConditionalValueatRiskRange — Type
struct OrderedWeightsArrayConditionalValueatRiskRange{__T_alpha, __T_beta} <: AbstractOrderedWeightsArrayFunctionCallable OWA weight estimator for the Conditional Value at Risk Range risk measure.
When called as r(T), returns the OWA weight vector for the CVaR range at lower confidence level alpha and upper confidence level beta for T observations.
Fields
alpha: Quantile level for the lower tail. The bound isNum_SigCal, so the slot takes the level itself, anAbstractSignificanceCalibrationAlgorithmthat computes it from the prior result, or a plain function of the same five arguments.
beta: Quantile level for the upper tail. The bound isNum_SigCal, so the slot takes the level itself, anAbstractSignificanceCalibrationAlgorithmthat computes it from the prior result, or a plain function of the same five arguments.
Constructors
OrderedWeightsArrayConditionalValueatRiskRange(; alpha::Num_SigCal = 0.05, beta::Num_SigCal = alpha) -> OrderedWeightsArrayConditionalValueatRiskRangeKeywords correspond to the struct's fields.
Validation
0 < alpha < 1.0 < beta < 1.
Examples
julia> OrderedWeightsArrayConditionalValueatRiskRange()OrderedWeightsArrayConditionalValueatRiskRange alpha ┼ Float64: 0.05 beta ┴ Float64: 0.05Related
References
- [103] R. T. Rockafellar and S. Uryasev. Optimization of conditional value-at-risk. Journal of Risk 2, 21–41 (2000).
- [107] D. Cajas. OWA portfolio optimization: A disciplined convex programming framework. Available at SSRN 3988927 (2021).
- [5] D. Cajas. Advanced Portfolio Optimization: A Cutting-edge Quantitative Approach (Springer Nature Switzerland, 2025). Section 7.2.3.
PortfolioOptimisers.OrderedWeightsArrayTailGiniRange — Type
struct OrderedWeightsArrayTailGiniRange{__T_alpha_i, __T_alpha, __T_a_sim, __T_beta_i, __T_beta, __T_b_sim} <: AbstractOrderedWeightsArrayFunctionCallable OWA weight estimator for the tail Gini range risk measure.
When called as r(T), returns the OWA weight vector for the difference between the lower and upper tail Gini measures, each approximated by integrating over CVaR levels.
Fields
alpha_i: Lower integration bound for the tail Gini approximation.
alpha: Quantile level for the lower tail. The bound isNum_SigCal, so the slot takes the level itself, anAbstractSignificanceCalibrationAlgorithmthat computes it from the prior result, or a plain function of the same five arguments.
a_sim: Number of integration points for the tail Gini approximation.
beta_i: Lower integration bound for the upper tail Gini approximation.
beta: Quantile level for the upper tail. The bound isNum_SigCal, so the slot takes the level itself, anAbstractSignificanceCalibrationAlgorithmthat computes it from the prior result, or a plain function of the same five arguments.
b_sim: Number of integration points for the upper tail Gini approximation.
Constructors
OrderedWeightsArrayTailGiniRange(; alpha_i::Number = 1e-4, alpha::Num_SigCal = 0.05, a_sim::Integer = 100, beta_i::Number = alpha_i, beta::Num_SigCal = alpha, b_sim::Integer = a_sim) -> OrderedWeightsArrayTailGiniRangeKeywords correspond to the struct's fields.
Validation
0 < alpha_i < alpha < 1, checked whenalphais a number. Whenalphaholds a Calibration Rule only0 < alpha_i < 1is checked here, and the joint bound is checked when the rebuild runs at fold time. A rule that returns a value at or below the statedalpha_iis refused there, and this joint bound is the whole of the ordering validation.a_sim > 0.0 < beta_i < beta < 1, checked whenbetais a number. Whenbetaholds a Calibration Rule only0 < beta_i < 1is checked here, and the joint bound is checked when the rebuild runs at fold time, on the terms the lower tail states.b_sim > 0.
Examples
julia> OrderedWeightsArrayTailGiniRange()OrderedWeightsArrayTailGiniRange alpha_i ┼ Float64: 0.0001 alpha ┼ Float64: 0.05 a_sim ┼ Int64: 100 beta_i ┼ Float64: 0.0001 beta ┼ Float64: 0.05 b_sim ┴ Int64: 100Related
References
- [111] W. Ogryczak and A. Ruszczyński. Dual stochastic dominance and quantile risk measures. International Transactions in Operational Research 9, 661–680 (2002).
- [107] D. Cajas. OWA portfolio optimization: A disciplined convex programming framework. Available at SSRN 3988927 (2021).
- [108] D. Cajas. Efficient Gini Mean Difference and Tail Gini Portfolio Optimization based on P-Norms. Available at SSRN 4711326 (2024).
- [5] D. Cajas. Advanced Portfolio Optimization: A Cutting-edge Quantitative Approach (Springer Nature Switzerland, 2025). Section 7.2.3.
PortfolioOptimisers.ExactOrderedWeightsArray — Type
struct ExactOrderedWeightsArray <: OrderedWeightsArrayFormulationOWA formulation that computes the exact OWA risk by solving a linear programme.
It adds two vector variables a and b of length T and the T × T block of constraints $y_{i} w_{j} \leq a_{j} + b_{i}$, and the risk is $\sum_{t} (a_{t} + b_{t})$. This is the dual of the assignment problem that orders the sample. It costs T^2 constraints, so ApproxOrderedWeightsArray is the cheaper choice for a long sample.
The programme pairs the largest weight with the largest sorted return, so it attains $\mathrm{sort}(\boldsymbol{\omega})^{\intercal} \mathrm{sort}(\hat{\boldsymbol{r}})$. This is the OWA risk when, and only when, the weight vector is monotonic non-decreasing, which is also the condition for the risk measure to be convex. Every weight builder in this package returns such a vector. A weight vector supplied out of order is sorted by the programme, so the model and the functor then disagree.
Related
References
- [110] W. Ogryczak and T. Śliwiński. On solving linear programs with the ordered weighted averaging objective. European Journal of Operational Research 148, 80–91 (2003).
- [107] D. Cajas. OWA portfolio optimization: A disciplined convex programming framework. Available at SSRN 3988927 (2021).
- [5] D. Cajas. Advanced Portfolio Optimization: A Cutting-edge Quantitative Approach (Springer Nature Switzerland, 2025). Section 7.1.5.
PortfolioOptimisers.ApproxOrderedWeightsArray — Type
struct ApproxOrderedWeightsArray{__T_p} <: OrderedWeightsArrayFormulationOWA formulation that approximates the OWA risk using a set of p-norm parameters.
It relaxes the dual representation of the OWA risk, replacing the T × T constraint block of ExactOrderedWeightsArray by one p-norm constraint for each entry of p. It keeps only the properties of the weight vector that a reordering leaves unchanged: the minimum, the maximum, the sum, and one p-norm for each entry of p. Every reordering of the weight vector meets those properties, so the risk is an upper bound on the exact OWA risk, and the gap closes as the weight vector approaches a line.
The source paper studies the linear case and reports the same objective value as the exact formulation, to its printed precision, for the Gini mean difference and the tail Gini over samples of 500 to 10,000 observations. Measured against the functor at T = 100, N = 8 with the default p, the Gini mean difference is 0.06 % high, the tail Gini is 1.7e-5 % high, and the tail Gini range is 0.37 % high. A fourth-order L-moment weight vector, which is not linear, is 4.5 % high. Prefer ExactOrderedWeightsArray for a weight vector that is far from a line, and this formulation for a long sample.
Fields
p: Vector of p-norm orders used to approximate the ordered weights array risk.
Constructors
ApproxOrderedWeightsArray(; p::VecNum = Float64[2, 3, 4, 10, 50]) -> ApproxOrderedWeightsArrayKeywords correspond to the struct's fields.
Validation
!isempty(p)andall(x -> x > 1, p).
Examples
julia> ApproxOrderedWeightsArray()ApproxOrderedWeightsArray p ┴ Vector{Float64}: [2.0, 3.0, 4.0, 10.0, 50.0]Related
References
- [108] D. Cajas. Efficient Gini Mean Difference and Tail Gini Portfolio Optimization based on P-Norms. Available at SSRN 4711326 (2024).
- [107] D. Cajas. OWA portfolio optimization: A disciplined convex programming framework. Available at SSRN 3988927 (2021).
- [5] D. Cajas. Advanced Portfolio Optimization: A Cutting-edge Quantitative Approach (Springer Nature Switzerland, 2025). Section 7.1.5.
PortfolioOptimisers.OrderedWeightsArray — Type
struct OrderedWeightsArray{__T_settings, __T_w, __T_alg} <: RiskMeasureOrdered Weights Array (OWA) risk measure.
Computes portfolio risk as a linear combination of sorted portfolio returns using OWA weights. The OWA weights can be provided directly or computed from an OWA algorithm.
Mathematical definition
\[\begin{align} \mathrm{OWA}_{\boldsymbol{w}}(\boldsymbol{x}) &= \sum_{t=1}^{T} w_{t} x_{(t)}\,. \end{align}\]
Where:
- $\mathrm{OWA}_{\boldsymbol{w}}(\boldsymbol{x})$: Ordered weights array risk.
- $\boldsymbol{x}$: Portfolio returns vector $T \times 1$.
- $T$: Number of observations.
- $\boldsymbol{w}$: OWA weight vector $T \times 1$.
- $x_{(t)}$: $t$-th smallest entry of $\boldsymbol{x}$, so $x_{(1)} \leq \dots \leq x_{(T)}$.
Fields
settings: Risk measure settings.
w: Optional OWA weight vector.
alg: Risk measure optimisation formulation algorithm.
Constructors
OrderedWeightsArray(; settings::RiskMeasureSettings = RiskMeasureSettings(), w::OWA_Func_VecNum = owa_gmd, alg::OrderedWeightsArrayFormulation = ApproxOrderedWeightsArray()) -> OrderedWeightsArrayKeywords correspond to the struct's fields.
Validation
- If
wis aVecNum:!isempty(w).
Functor
(r::OrderedWeightsArray)(x::VecNum)Computes the OWA risk of a portfolio returns vector x. A w that is a callable is evaluated at length(x) first, so the weight vector always matches the sample.
Arguments
x::VecNum: Portfolio returns vector.
Examples
julia> OrderedWeightsArray()OrderedWeightsArray settings ┼ RiskMeasureSettings │ scale ┼ Float64: 1.0 │ ub ┼ nothing │ rke ┴ Bool: true w ┼ typeof(owa_gmd): PortfolioOptimisers.owa_gmd alg ┼ ApproxOrderedWeightsArray │ p ┴ Vector{Float64}: [2.0, 3.0, 4.0, 10.0, 50.0]Related
OrderedWeightsArrayRangeOrderedWeightsArrayFormulationExactOrderedWeightsArrayApproxOrderedWeightsArrayRiskMeasureSettings
References
- [110] W. Ogryczak and T. Śliwiński. On solving linear programs with the ordered weighted averaging objective. European Journal of Operational Research 148, 80–91 (2003).
- [107] D. Cajas. OWA portfolio optimization: A disciplined convex programming framework. Available at SSRN 3988927 (2021).
- [5] D. Cajas. Advanced Portfolio Optimization: A Cutting-edge Quantitative Approach (Springer Nature Switzerland, 2025). Section 7.1.5.
PortfolioOptimisers.OrderedWeightsArrayRange — Type
struct OrderedWeightsArrayRange{__T_settings, __T_w1, __T_w2, __T_alg, __T_rev} <: RiskMeasureOrdered Weights Array Range (OWA Range) risk measure.
Computes portfolio risk as the difference between two OWA linear combinations of sorted portfolio returns, providing a range-based risk measure.
The constructor reverses w2 unless the caller declares that it is already reversed (see rev). That reversal is what makes the difference of the two weight vectors a range: w1 addresses the lower tail of the sorted returns, and the reversed w2 addresses the upper tail, so w1 - w2 sums the two tails rather than cancelling them. It is the weight-space form of the convention ValueatRiskRange states on the returns themselves.
Mathematical definition
\[\begin{align} \mathrm{OWARange}_{\boldsymbol{w}_{1},\boldsymbol{w}_{2}}(\boldsymbol{x}) &= \sum_{t=1}^{T} \left(w_{1,t} - w_{2,t}\right) x_{(t)}\,. \end{align}\]
Where:
- $\mathrm{OWARange}_{\boldsymbol{w}_{1},\boldsymbol{w}_{2}}(\boldsymbol{x})$: Ordered weights array range.
- $\boldsymbol{x}$: Portfolio returns vector $T \times 1$.
- $T$: Number of observations.
- $\boldsymbol{w}_{1}$: Lower-tail OWA weight vector $T \times 1$.
- $\boldsymbol{w}_{2}$: Upper-tail OWA weight vector $T \times 1$, held reversed by the constructor.
- $x_{(t)}$: $t$-th smallest entry of $\boldsymbol{x}$, so $x_{(1)} \leq \dots \leq x_{(T)}$.
Fields
settings: Risk measure settings.
w1: Optional first OWA weight vector.
w2: Optional second OWA weight vector.
alg: Risk measure optimisation formulation algorithm.
rev: Whetherw2is already reversed. It is a done-flag, not an instruction: the constructor reversesw2whenrev == false, and leaves it as-is whenrev == true. The field is stored astruewhatever the caller passes, becausew2is reversed by the time the object exists, so rebuilding an instance from its own fields does not reverse twice. A default-constructed instance therefore printsrevastrue.
Constructors
OrderedWeightsArrayRange(; settings::RiskMeasureSettings = RiskMeasureSettings(), w1::OWA_Func_VecNum = owa_tg, w2::OWA_Func_VecNum = owa_tg, alg::OrderedWeightsArrayFormulation = ApproxOrderedWeightsArray(), rev::Bool = false) -> OrderedWeightsArrayRangeKeywords correspond to the struct's fields.
Validation
- If
w1is aVecNum:!isempty(w1). - If
w2is aVecNum:!isempty(w2). - If both
w1andw2areVecNum:length(w1) == length(w2).
Functor
(r::OrderedWeightsArrayRange)(x::VecNum)Computes the OWA range of a portfolio returns vector x, as the sorted returns weighted by w1 - w2. A w1 or w2 that is a callable is evaluated at length(x) first, so the weight vectors always match the sample.
Arguments
x::VecNum: Portfolio returns vector.
Examples
julia> OrderedWeightsArrayRange()OrderedWeightsArrayRange settings ┼ RiskMeasureSettings │ scale ┼ Float64: 1.0 │ ub ┼ nothing │ rke ┴ Bool: true w1 ┼ typeof(owa_tg): PortfolioOptimisers.owa_tg w2 ┼ ComposedFunction{typeof(reverse), typeof(owa_tg)}: reverse ∘ PortfolioOptimisers.owa_tg alg ┼ ApproxOrderedWeightsArray │ p ┴ Vector{Float64}: [2.0, 3.0, 4.0, 10.0, 50.0] rev ┴ Bool: trueRelated
OrderedWeightsArrayOrderedWeightsArrayFormulationExactOrderedWeightsArrayApproxOrderedWeightsArrayRiskMeasureSettings
References
- [110] W. Ogryczak and T. Śliwiński. On solving linear programs with the ordered weighted averaging objective. European Journal of Operational Research 148, 80–91 (2003).
- [107] D. Cajas. OWA portfolio optimization: A disciplined convex programming framework. Available at SSRN 3988927 (2021).
- [5] D. Cajas. Advanced Portfolio Optimization: A Cutting-edge Quantitative Approach (Springer Nature Switzerland, 2025). Section 7.2.3.
PortfolioOptimisers.OWAJuMP — Type
struct OWAJuMP{__T_slv, __T_max_phi, __T_sc, __T_so, __T_alg} <: AbstractOrderedWeightsArrayEstimatorEstimator type for OWA weights using JuMP-based optimization.
OWAJuMP encapsulates all configuration required to estimate OWA weights via mathematical programming using JuMP. It supports multiple algorithms and solver backends, and allows fine control over constraints and scaling.
Fields
slv: Solver or vector of solvers.
max_phi: Maximum allowed value for any OWA weight.
sc: Constraint scale factor.
so: Objective scale factor.
alg: Risk measure optimisation formulation algorithm.
Constructors
OWAJuMP(; slv::Slv_VecSlv, max_phi::Number = 0.5, sc::Number = 1.0, so::Number = 1.0, alg::AbstractOrderedWeightsArrayAlgorithm = MaximumEntropy(),) -> OWAJuMPKeyword arguments correspond to the struct's fields.
Validation
!isempty(slv).0 < max_phi < 1.isfinite(sc)andsc > 0.isfinite(so)andso > 0.
Examples
julia> OWAJuMP(; slv = Solver(; solver = nothing))OWAJuMP slv ┼ Solver │ name ┼ String: "" │ solver ┼ nothing │ settings ┼ nothing │ check_sol ┼ @NamedTuple{}: NamedTuple() │ add_bridges ┴ Bool: true max_phi ┼ Float64: 0.5 sc ┼ Float64: 1.0 so ┼ Float64: 1.0 alg ┼ MaximumEntropy │ alg ┴ RelativeEntropy()Related
AbstractOrderedWeightsArrayEstimatorAbstractOrderedWeightsArrayAlgorithmowa_l_moment_crmSolverSlv_VecSlv
References
- [109] D. Cajas. Higher order moment portfolio optimization with L-moments. Available at SSRN 4393155 (2023).
PortfolioOptimisers.factory — Method
factory(
x::OrderedWeightsArray,
pr::AbstractPriorResult,
args...;
kwargs...
) -> OrderedWeightsArray
Resolve the weight builder in w against prior result pr, and return an OrderedWeightsArray whose builder holds numbers.
The measure carries no propagation tag, so it generates no prior factory method of its own and this is the channel the value-level entry points take. The JuMP route reaches the same recursion through set_risk_constraints!, which calls resolve_deferred_quantities directly.
A builder holding numbers, a weight vector and a plain function are all carried through unchanged, so the common case allocates nothing.
Related
PortfolioOptimisers.factory — Method
factory(
x::OrderedWeightsArrayRange,
pr::AbstractPriorResult,
args...;
kwargs...
) -> OrderedWeightsArrayRange
Resolve the two weight builders of an OrderedWeightsArrayRange against prior result pr.
It carries the reading of factory on OrderedWeightsArray unchanged, over two builders instead of one.
Related
PortfolioOptimisers.owa_l_moment_crm — Function
owa_l_moment_crm(method::AbstractOrderedWeightsArrayEstimator, weights::MatNum)Compute Ordered Weights Array (OWA) linear moment convex risk measure (CRM) weights using various estimation methods.
This function dispatches on the estimator method to compute OWA weights from a matrix of moment or order-statistic weights. It supports several OWA estimation approaches, including normalised constant relative risk aversion (CRRA) and JuMP-based optimization with different algorithms.
Arguments
method::NormalisedConstantRelativeRiskAversion: Computes OWA weights using the normalised CRRA scheme, parameterised by the risk aversion parameterginmethod. The resulting weights interpolate between risk-neutral and risk-averse profiles.method::OWAJuMP{<:Any, <:Any, <:Any, <:Any, <:MaximumEntropy}: Computes OWA weights by solving a maximum entropy optimization problem using JuMP. This yields the most "uninformative" or uniform OWA weights subject to the imposed constraints.method::OWAJuMP{<:Any, <:Any, <:Any, <:Any, <:MinimumSquaredDistance}: Computes OWA weights by minimizing the sum of squared differences between adjacent OWA weights. There is no target vector; the objective is a smoothness penalty over the order statistics.method::OWAJuMP{<:Any, <:Any, <:Any, <:Any, <:MinimumSumSquares}: Computes OWA weights by minimizing the sum of squared OWA weights. This is a ridge penalty, so it spreads the weight mass rather than concentrating it.weights: Matrix of weights (e.g., order statistics or moment weights).
Returns
w::VecNum: Vector of OWA weights of lengthsize(weights, 1).
Related
NormalisedConstantRelativeRiskAversionOWAJuMPMaximumEntropyMinimumSquaredDistanceMinimumSumSquaresMatNumncrra_weights
References
- [109] D. Cajas. Higher order moment portfolio optimization with L-moments. Available at SSRN 4393155 (2023).
owa_l_moment_crm(T::Integer,
method::AbstractOrderedWeightsArrayEstimator = NormalisedConstantRelativeRiskAversion();
k::Integer = 2)Compute the ordered weights array (OWA) linear moments convex risk measure (CRM) weights for a given number of observations and moment order.
This function constructs the OWA linear moment CRM weights matrix for order statistics of size T and moment orders from 2 up to k, and then applies the specified OWA estimation method to produce the final OWA weights.
Arguments
T: Number of observations.k: Highest moment order to include.method: OWA estimator.
Validation
k >= 2.
Returns
w::VecNum: Vector of OWA weights of lengthT.
Details
- Constructs a matrix of OWA moment weights for each moment order from 2 to
k. Columni - 1holds $\left(-1\right)^{i}$ times the weight vector ofowa_l_moment(T, i), which is the alternating sign of the convex risk measure. - Each L-moment weight vector of order
k >= 2sums to zero, so the returned OWA weight vector does not sum to one. It is the risk aversion coefficients that are normalised. - Applies the specified OWA estimation method to aggregate the moment weights into a single OWA weight vector.
Mathematical definition
\[\begin{align} \rho(\boldsymbol{w}) &= \sum\limits_{k=2}^{K} \left(-1\right)^{k} \phi_{k} \lambda_{k}\left(\hat{\boldsymbol{r}}\right)\\ &= \sum\limits_{i=1}^{T} \eta_{i} \hat{r}_{[i]}\\ \eta_{i} &= \sum\limits_{k=2}^{K} \left(-1\right)^{k} \phi_{k} \omega_{i}^{k}\,. \end{align}\]
Where:
- $\rho(\boldsymbol{w})$: Is the L-moment convex risk measure of the portfolio.
- $\phi_{k}$: Is the risk aversion coefficient of the
k-th L-moment, whichmethodfinds. - $\omega_{i}^{k}$: Is the weight of the
i-th order statistic in thek-th L-moment. - $\boldsymbol{\eta}$: Is the returned OWA weight vector.
- $K$: Is the highest moment order,
k. - $T$: Is the total number of observations.
Related
References
PortfolioOptimisers.owa_l_moment — Function
owa_l_moment(T::Integer, k::Integer = 2)Compute the linear moment weights for the linear moments convex risk measure (CRM).
This function returns the vector of weights for the OWA linear moment of order k for T observations. The k-th sample L-moment is the weighted sum of the order statistics of the sample, so an L-moment is an OWA operator and this function returns its weight vector.
Mathematical definition
\[\begin{align} \omega_{i}^{k} &= \dfrac{1}{k} \binom{T}{k}^{-1} \sum\limits_{j=0}^{k-1} \left(-1\right)^{j} \binom{k-1}{j} \binom{i-1}{k-1-j} \binom{T-i}{j}\\ \lambda_{k} &= \sum\limits_{i=1}^{T} \omega_{i}^{k} y_{[i]}\,. \end{align}\]
Where:
- $\omega_{i}^{k}$: Is the weight of the
i-th order statistic in thek-th L-moment. - $\lambda_{k}$: Is the
k-th sample L-moment. - $y_{[i]}$: Is the
i-th order statistic of the sample, in ascending order. - $T$: Is the total number of observations.
- $k$: Is the moment order.
Arguments
T: Number of observations.k: Moment order.
Returns
w::VecNum: Vector of OWA weights of lengthT. Fork >= 2it sums to zero.
Related
References
PortfolioOptimisers.owa_gmd — Function
owa_gmd(T::Integer)Compute the Ordered Weights Array (OWA) of the Gini Mean Difference (GMD) risk measure.
Arguments
T: Number of observations.
Returns
w::VecNum: Vector of OWA weights of lengthT. It is returned lazily as a range, and its entries sum to zero.
Related
References
- [112] S. Yitzhaki. Stochastic dominance, mean variance, and Gini's mean difference. The American Economic Review 72, 178–185 (1982).
- [107] D. Cajas. OWA portfolio optimization: A disciplined convex programming framework. Available at SSRN 3988927 (2021).
- [108] D. Cajas. Efficient Gini Mean Difference and Tail Gini Portfolio Optimization based on P-Norms. Available at SSRN 4711326 (2024).
- [5] D. Cajas. Advanced Portfolio Optimization: A Cutting-edge Quantitative Approach (Springer Nature Switzerland, 2025). Section 7.2.1.2.
PortfolioOptimisers.owa_cvar — Function
owa_cvar(T::Integer, alpha::Number = 0.05)Compute the Ordered Weights Array (OWA) weights for the Conditional Value at Risk.
Arguments
T: Number of observations.alpha: Confidence level for CVaR.
Validation
0 < alpha < 1.
Returns
w::VecNum: Vector of OWA weights of lengthT.
Related
References
- [103] R. T. Rockafellar and S. Uryasev. Optimization of conditional value-at-risk. Journal of Risk 2, 21–41 (2000).
- [107] D. Cajas. OWA portfolio optimization: A disciplined convex programming framework. Available at SSRN 3988927 (2021).
- [5] D. Cajas. Advanced Portfolio Optimization: A Cutting-edge Quantitative Approach (Springer Nature Switzerland, 2025). Section 7.2.2.4.
PortfolioOptimisers.owa_wcvar — Function
owa_wcvar(T::Integer, alphas::VecNum, weights::VecNum)Compute the Ordered Weights Array (OWA) weights for a weighted combination of Conditional Value at Risk measures.
Arguments
T: Number of observations.alphas: Vector of confidence levels.weights: Vector of weights.
Returns
w::VecNum: Vector of OWA weights of lengthT.
Related
PortfolioOptimisers.owa_tg — Function
owa_tg(T::Integer; alpha_i::Number = 1e-4, alpha::Number = 0.05, a_sim::Integer = 100)Compute the Ordered Weights Array (OWA) weights for the tail Gini risk measure.
This function approximates the tail Gini risk measure by integrating over a range of CVaR levels from alpha_i to alpha, using a_sim points. The resulting weights are suitable for tail risk assessment.
Arguments
T: Number of observations.alpha_i: Lower bound for CVaR integration.alpha: Upper bound for CVaR integration.a_sim: Number of integration points.
Validation
0 < alpha_i < alpha < 1.a_sim > 0.
Returns
w::VecNum: Vector of OWA weights of lengthT.
Related
References
- [111] W. Ogryczak and A. Ruszczyński. Dual stochastic dominance and quantile risk measures. International Transactions in Operational Research 9, 661–680 (2002).
- [107] D. Cajas. OWA portfolio optimization: A disciplined convex programming framework. Available at SSRN 3988927 (2021).
- [108] D. Cajas. Efficient Gini Mean Difference and Tail Gini Portfolio Optimization based on P-Norms. Available at SSRN 4711326 (2024).
- [5] D. Cajas. Advanced Portfolio Optimization: A Cutting-edge Quantitative Approach (Springer Nature Switzerland, 2025). Section 7.2.2.5.
PortfolioOptimisers.owa_wr — Function
owa_wr(T::Integer)Compute the Ordered Weights Array (OWA) weights for the worst realisation risk measure.
This function returns a vector of OWA weights that select the minimum (worst) value among T observations.
Arguments
T: Number of observations.
Returns
w::VecNum: Vector of OWA weights of lengthT.
Related
PortfolioOptimisers.owa_rg — Function
owa_rg(T::Integer)Compute the Ordered Weights Array (OWA) weights for the range risk measure.
This function returns a vector of OWA weights corresponding to the range (difference between maximum and minimum) returns among T observations.
Arguments
T: Number of observations.
Returns
w::VecNum: Vector of OWA weights of lengthT.
Related
PortfolioOptimisers.owa_cvarrg — Function
owa_cvarrg(T::Integer; alpha::Number = 0.05, beta::Number = alpha)Compute the Ordered Weights Array (OWA) weights for the Conditional Value at Risk Range risk measure.
This function returns a vector of OWA weights corresponding to the difference between CVaR at level alpha (lower tail) and the reversed CVaR at level beta (upper tail).
Arguments
T: Number of observations.alpha: CVaR confidence level for the lower tail.beta: CVaR confidence level for the upper tail.
Returns
w::VecNum: Vector of OWA weights of lengthT.
Related
PortfolioOptimisers.owa_wcvarrg — Function
owa_wcvarrg(T::Integer, alphas::VecNum, weights_a::VecNum,
betas::VecNum = alphas,
weights_b::VecNum = weights_a)Compute the Ordered Weights Array (OWA) weights for the weighted Conditional Value at Risk Range risk measure.
This function returns a vector of OWA weights corresponding to the difference between a weighted sum of CVaR measures at levels alphas with weights weights_a and the reversed weighted sum of CVaR measures at levels betas with weights weights_b.
Arguments
T: Number of observations.alphas: Vector of lower tail CVaR confidence levels.weights_a: Vector of weights for lower tail CVaR.betas: Vector of upper tail CVaR confidence levels.weights_b: Vector of weights for upper tail CVaR.
Returns
w::VecNum: Vector of OWA weights of lengthT.
Related
PortfolioOptimisers.owa_tgrg — Function
owa_tgrg(T::Integer; alpha_i::Number = 0.0001, alpha::Number = 0.05, a_sim::Integer = 100,
beta_i::Number = alpha_i, beta::Number = alpha, b_sim::Integer = a_sim)Compute the Ordered Weights Array (OWA) weights for the tail Gini range risk measure.
This function returns a vector of OWA weights corresponding to the difference between tail Gini measures for the lower and upper tails, each approximated by integrating over a range of CVaR levels.
Arguments
T: Number of observations.alpha_i: Lower bound for lower tail CVaR integration.alpha: Upper bound for lower tail CVaR integration.a_sim: Number of integration points for lower tail.beta_i: Lower bound for upper tail CVaR integration.beta: Upper bound for upper tail CVaR integration.b_sim: Number of integration points for upper tail.
Returns
w::VecNum: Vector of OWA weights of lengthT.
Related
References
- [5]
- D. Cajas. Advanced Portfolio Optimization: A Cutting-edge Quantitative Approach (Springer Nature Switzerland, 2025).
- [103]
- R. T. Rockafellar and S. Uryasev. Optimization of conditional value-at-risk. Journal of Risk 2, 21–41 (2000).
- [107]
- D. Cajas. OWA portfolio optimization: A disciplined convex programming framework. Available at SSRN 3988927 (2021).
- [108]
- D. Cajas. Efficient Gini Mean Difference and Tail Gini Portfolio Optimization based on P-Norms. Available at SSRN 4711326 (2024).
- [109]
- D. Cajas. Higher order moment portfolio optimization with L-moments. Available at SSRN 4393155 (2023).
- [110]
- W. Ogryczak and T. Śliwiński. On solving linear programs with the ordered weighted averaging objective. European Journal of Operational Research 148, 80–91 (2003).
- [111]
- W. Ogryczak and A. Ruszczyński. Dual stochastic dominance and quantile risk measures. International Transactions in Operational Research 9, 661–680 (2002).
- [112]
- S. Yitzhaki. Stochastic dominance, mean variance, and Gini's mean difference. The American Economic Review 72, 178–185 (1982).