Correlation - Number of pairings

emilioalzamora1

Well-Known Member
Hi @David Harper CFA FRM,

I had to think about it myself for some minutes: just wanted to share this with the community here.

Let's say we have 18 assets. How many correlation pairs would we have?

We could go the long road writing:

Asset (A,B)
Asset (A,C)
Asset (A,D)
...
...
Asset (B,C) etc.

but the easier way is for the covariance we would have: n*(n-1) /2 = 18*(18-1) / 2 = 153 pairs

The full variance-c0variance would be: n*(n-1) / 2 + N (variance terms) = 153 + 178 = 171 pairs

Here is some proof:

http://sites.millersville.edu/bikenaga/math-proof/induction/induction.html
 

David Harper CFA FRM

David Harper CFA FRM
Subscriber
Hi @emilioalzamora1 Hey i hope you are doing well! I agree ... one of my "first loves" in math was triangle numbers (https://en.wikipedia.org/wiki/Triangular_number)
I have an illustration here https://forum.bionicturtle.com/thre...lls-tau-and-concordant-discordant-pairs.8209/ albeit in the context of concordant/discordant pairs:
010915-kendalls.png



If you have (n) assets in the square matrix (as a special case of a rectangle), then there are n^2 elements in the square. But the diagonal contains the self-referencing pairs (either 1.0 in the case of correlation matrix, or variances in the covariance matrix) so there are n^2 - n non-identity pairs. Except the upper triangle is a mirror of the lower triangle, so there are (n^2 - n)/2 = n*(n-1)/2 unique, non-identity pairs. Thank you for the proof, I will take a look, I just like the visual elegance of it all :)
 
Top