Loading [MathJax]/jax/output/CommonHTML/jax.js

EXAMPLE 4 Calculating the correlation coefficient r

highlowtemp

Find the value of the correlation coefficient r for the temperature data in Table 3.

Solution

We will outline the steps used in calculating the value of r using the temperature data.

  • Step 1 Calculate the respective sample means, ˉx and ˉy.

    ˉx=xn=40,ˉy=yn=64

  • Step 2 Construct a table, as shown here in Table 4.
    Page 194
    Table 4.4: Table 4 Calculation table for the correlation coefficient r
    City x y (xˉx) (xˉx)2 (yˉy) (yˉy)2 (xˉx) (yˉy)
    Boston 30 50 −10 100 −14 196 140
    Chicago 35 55 −5 25 −9 81 45
    Philadelphia 40 70 0 0 6 36 0
    Washington, DC 45 65 5 25 1 1 5
    Dallas 50 80 10 100 16 256 160
    (xˉx)2=250 (yˉy)2=570 (xˉx)(yˉy)=350

    Note on Rounding: Whenever you calculate a quantity that will be needed for later calculations, do not round. Round only when you arrive at the final answer. Here, because the quantities sx and sy are used to calculate the correlation coefficient r, neither of them is rounded until the end of the calculation.

  • Step 3 Calculate the respective sample standard deviations sx and sy. Using the sums calculated from Table 4, we have

    sx=(xˉx)2n1=250517.90569415andsy=(yˉy)2n1=5705111.93733639

  • Step 4 Put these values all together in the formula for the correlation coefficient r:

    r=(xˉx)(yˉy)(n1)sxsy=350(4)(7.90569415)(11.93733639)0.927172650.9272

The correlation coefficient r for the high and low temperatures is 0.9272.

NOW YOU CAN DO

Exercises 13c–20c.

[Leave] [Close]