STA169 · 2080 · 10 marks
Correlation and Regression Analysis
Correlation and Regression Analysis
Correlation and Regression Analysis
Given Data
$n = 8$
| Number of weeks (x) | 4 | 5 | 3 | 9 | 7 | 10 | 4 | 5 |
|---|---|---|---|---|---|---|---|---|
| Speed gain (y) | 85 | 120 | 48 | 192 | 164 | 234 | 74 | 110 |
Meaning of Correlation Types
i. Positive Correlation: Two variables move in the same direction. When one increases, the other also increases (and vice versa). Example: height and weight.
ii. Negative Correlation: Two variables move in opposite directions. When one increases, the other decreases. Example: price and demand.
iii. Perfect Correlation: A change in one variable produces an exactly proportional change in the other, so all points lie on a straight line. Perfect positive gives $r = +1$; perfect negative gives $r = -1$.
Calculation Table
| x | y | x² | y² | xy |
|---|---|---|---|---|
| 4 | 85 | 16 | 7225 | 340 |
| 5 | 120 | 25 | 14400 | 600 |
| 3 | 48 | 9 | 2304 | 144 |
| 9 | 192 | 81 | 36864 | 1728 |
| 7 | 164 | 49 | 26896 | 1148 |
| 10 | 234 | 100 | 54756 | 2340 |
| 4 | 74 | 16 | 5476 | 296 |
| 5 | 110 | 25 | 12100 | 550 |
| Σx=47 | Σy=1027 | Σx²=321 | Σy²=160021 | Σxy=7146 |
Verification of sums: $\Sigma x = 47$, $\Sigma y = 1027$, $\Sigma x^2 = 321$, $\Sigma xy = 7146$, and $\Sigma y^2 = 160021$. All confirmed.
Part (a): Correlation Coefficient
$$r = \frac{n\Sigma xy - \Sigma x \Sigma y}{\sqrt{[n\Sigma x^2 - (\Sigma x)^2][n\Sigma y^2 - (\Sigma y)^2]}}$$
Numerator: $$8(7146) - 47(1027) = 57168 - 48269 = 8899$$
First bracket: $$8(321) - 47^2 = 2568 - 2209 = 359$$
Second bracket: $$8(160021) - 1027^2 = 1280168 - 1054729 = 225439$$
$$r = \frac{8899}{\sqrt{359 \times 225439}} = \frac{8899}{\sqrt{80932601}} = \frac{8899}{8996.26}$$
$$\boxed{r \approx 0.989}$$
Interpretation: Since $r = 0.989$ is very close to $+1$, there is a very high positive correlation between weeks in the program and speed gain. As weeks increase, speed gain increases strongly.
Part (b): Regression Equation of Speed Gain (y) on Weeks (x)
$$\hat{y} = a + bx$$
$$b = \frac{n\Sigma xy - \Sigma x \Sigma y}{n\Sigma x^2 - (\Sigma x)^2} = \frac{8899}{359} = 24.79$$
$$\bar{x} = \frac{47}{8} = 5.875, \quad \bar{y} = \frac{1027}{8} = 128.375$$
$$a = \bar{y} - b\bar{x} = 128.375 - 24.79(5.875) = 128.375 - 145.64 = -17.26$$
$$\boxed{\hat{y} = -17.26 + 24.79x}$$
Part (c): Estimate for 6 Weeks and Slope Interpretation
$$\hat{y} = -17.26 + 24.79(6) = -17.26 + 148.74 = 131.48$$
$$\boxed{\hat{y} \approx 131.48 \text{ units of speed gain}}$$
Slope interpretation: $b = 24.79$ means that for each additional week in the program, the reading speed gain increases by about 24.79 units on average.
Short on time? The 1, 5 and 10 mark versions of this answer, flashcards and practice sets come with a program pass.