Borrar filtros
Borrar filtros

How can calculate this formula?

1 visualización (últimos 30 días)
fede
fede el 5 de Nov. de 2015
Editada: Torsten el 6 de Nov. de 2015
I have a matrix of price time series (p1,p2...pn) and their weights w(1,n). How can calculate this formula?

Respuestas (1)

Matt J
Matt J el 5 de Nov. de 2015
Editada: Matt J el 5 de Nov. de 2015
v = w(:) .* sigma(:);
sigmaIndex = v.' * rho * v;
  3 comentarios
Matt J
Matt J el 5 de Nov. de 2015
I had a typo. The 2nd line should be
sigmaIndex = v.' * rho * v;
If that wasn't the misunderstanding, it's unclear what is. All of the variables are from notation given by you in your post.
Torsten
Torsten el 6 de Nov. de 2015
Editada: Torsten el 6 de Nov. de 2015
Note that the diagonal of the matrix rho has to be set to 1.
Best wishes
Torsten.

Iniciar sesión para comentar.

Categorías

Más información sobre Resizing and Reshaping Matrices 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