How do I find the global minimum variance portfolio?

41 visualizaciones (últimos 30 días)
Calum Crichton
Calum Crichton el 31 de En. de 2016
Respondida: Alejandra Pena-Ordieres el 3 de Dic. de 2021
Hi everyone,
Just wondered how you find the GMV portfolio? I have used this code http://www.mathworks.com/matlabcentral/fileexchange/36159-global-minimum-variance-model-and-1-n-model-optimal-asset-allocation but I wondered if there was another way?

Respuestas (1)

Alejandra Pena-Ordieres
Alejandra Pena-Ordieres el 3 de Dic. de 2021
Hi Calum,
I understand that you want to find the minimum variance portfolio. You can do this in two ways.
1) The easiest way is to use the Portfolio object. Assume that you have the mean (mu) and covariance (Sigma) of the returns. Then, you can find the minimum variance portfolio like this:
% Define Portfolio object
p = Portfolio('AssetCovar',Sigma,'AssetMean',mu);
p = setDefaultConstraints(p); % Long-only fully-invested portfolio
% Find minimum variance portfolio
w = p.estimateFrontierLimits('min');
Here ( https://www.mathworks.com/help/finance/when-to-use-portfolio-over-problem-based-framework.html ) you can find a list of the portfolio optimization problems that can be solved using the Portfolio object.
2) The second way is to write an optimization problem and solve it:
% Portfolio problem
prob = optimproblem('ObjectiveSense','minimize');
% Variables
% Portfolio weights
x = optimvar('x',nAssets,1,'LowerBound',0); % x >= 0 (long-only portfolio)
% Objective
% min x'*Sigma*x (Variance)
prob.Objective = x'*Sigma*x;
% Constraints
% Sum of weights equal to 1 (fully-invested)
prob.Constraints.sumToTau = sum(x) == 1;
% Solve problem
sol = solve(prob);
w = sol.x;
Hope this helps!
Alejandra

Categorías

Más información sobre Portfolio Optimization and Asset Allocation en Help Center y File Exchange.

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by