242 Chapter 8
Next we want to calculate the covariance of the returns. The covariance
(and the correlation coeffi cient, which is derived from it) measures the
degree to which the returns on the two assets move together. The defi ni-
tion is
Cov ,
,,
()[()][()]rr
M
rErrEr
WMT TGT WMT t WMT WMT t WMT
t
=−⋅−
∑
1
where M is the number of points in the distribution (in our case, M =
60). This computation is easily set up in Excel:
1
2
3
4
5
6
7
8
9
10
11
12
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
ABCDEFGH I J K
Date WMT Return
Return
minus
mean
TGT Return
Return
minus
mean
Product
5-Jul-01 26.07 37.40
1-Aug-01 22.00 -16.97% -18.56% 33.53 -10.92% -11.38% <-- =G4-$G$65 0.0211 <-- =D4*H4
4-Sep-01 20.07 -9.18% -10.77% 30.73 -8.72% -9.18% 0.0099
1-Oct-01 20.02 -0.25% -1.84% 30.15 -1.91% -2.36% 0.0004
1-Nov-01 23.35 15.39% 13.80% 36.38 18.78% 18.33% 0.0253
3-Dec-01 24.79 5.98% 4.40% 39.79 8.96% 8.50% 0.0037
2-Jan-02 23.03 -7.36% -8.95% 43.04 7.85% 7.40% -0.0066
4-Feb-02 18.09 -24.14% -25.73% 40.66 -5.69% -6.14% 0.0158
1-Mar-02 19.17 5.80% 4.21% 41.85 2.88% 2.43% 0.0010
1-Apr-02 20.25 5.48% 3.89% 42.36 1.21% 0.76% 0.0003
1-Nov-05 52.19 2.44% 0.85% 53.31 -3.79% -4.25% -0.0004
1-Dec-05 55.31 5.81% 4.22% 54.76 2.68% 2.23% 0.0009
3-Jan-06 55.63 0.58% -1.01% 54.54 -0.40% -0.86% 0.0001
1-Feb-06 58.46 4.96% 3.37% 54.29 -0.46% -0.92% -0.0003
1-Mar-06 60.23 2.98% 1.39% 51.90 -4.50% -4.96% -0.0007
3-Apr-06 65.46 8.33% 6.74% 52.99 2.08% 1.62% 0.0011
1-May-06 60.84 -7.32% -8.91% 48.92 -7.99% -8.45% 0.0075
1-Jun-06 67.51 10.40% 8.81% 48.87 -0.10% -0.56% -0.0005
3-Jul-06 67.65 0.21% -1.38% 49.17 0.61% 0.16% 0.0000
Average 1.59% <-- =AVERAGE(C4:C63) 0.46% Covariance 0.0038 <-- =AVERAGE(J4:J63)
Standard deviation 9.63% <-- =STDEVP(D4:D63) 7.19% 0.0038 <-- =COVAR(D4:D63,H4:H63)
Correlation 0.5484 <-- =J65/(C66*G66)
0.5484 <-- =J65/(STDEVP(C4:C63)*STDEVP(G4:G63))
0.5484 <-- =CORREL(C4:C63,G4:G63)
COMPUTING THE COVARIANCE FOR WALMART (WMT) AND TARGET (TGT)
The column Product contains the multiple of the deviation from the
mean in each month, that is, the terms [r
WMT,t
− E(r
WMT
)] [r
TGM,t
− E(r
TGT
)],
for t = 1, . . . , 12. The covariance is Average(product) = 0.0038. While it
is worthwhile calculating the covariance this way at least once, there is
a shorter way, which is also illustrated: The Excel function Covar(SLE
returns,BBY returns) calculates the covariance directly. To calculate the
covariance using Covar there is no necessity to fi nd the difference
between the returns and the means. Simply use Covar directly on the
columns, as illustrated in cell J66 of the spreadsheet.
The covariance is a hard number to interpret, since its size depends
on the units in which we measure the returns. (If we were to write the