How to calculate this formula?
1 Ansicht (letzte 30 Tage)
Ältere Kommentare anzeigen
fede
am 5 Nov. 2015
Beantwortet: Star Strider
am 5 Nov. 2015
I have a vector of weight w(1,n) and a vector of correlation p(n,1). How can calculate this formula?
![](https://www.mathworks.com/matlabcentral/answers/uploaded_files/151422/image.png)
Akzeptierte Antwort
Star Strider
am 5 Nov. 2015
See if this works:
wij = triu(bsxfun(@times, w, w'));
num = wij*p;
den = sum(wij(:));
pr = sum(num(:))/den);
0 Kommentare
Weitere Antworten (0)
Siehe auch
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!