In: Statistics and Probability
| X | Y | XY | X² | Y² | 
| 77 | 82 | 6314 | 5929 | 6724 | 
| 50 | 66 | 3300 | 2500 | 4356 | 
| 71 | 78 | 5538 | 5041 | 6084 | 
| 72 | 34 | 2448 | 5184 | 1156 | 
| 81 | 47 | 3807 | 6561 | 2209 | 
| 94 | 85 | 7990 | 8836 | 7225 | 
| 96 | 99 | 9504 | 9216 | 9801 | 
| 99 | 99 | 9801 | 9801 | 9801 | 
| 67 | 68 | 4556 | 4489 | 4624 | 
| Ʃx = | Ʃy = | Ʃxy = | Ʃx² = | Ʃy² = | 
| 707 | 658 | 53258 | 57557 | 51980 | 
| Sample size, n = | 9 | 
| x̅ = Ʃx/n = 707/9 = | 78.55555556 | 
| y̅ = Ʃy/n = 658/9 = | 73.11111111 | 
| SSxx = Ʃx² - (Ʃx)²/n = 57557 - (707)²/9 = | 2018.222222 | 
| SSyy = Ʃy² - (Ʃy)²/n = 51980 - (658)²/9 = | 3872.888889 | 
| SSxy = Ʃxy - (Ʃx)(Ʃy)/n = 53258 - (707)(658)/9 = | 1568.444444 | 
Sum of Square error, SSE = SSyy -SSxy²/SSxx
= 3872.88889 - (1568.44444)²/2018.22222 = 2653.985466
Standard error, se = √(SSE/(n-2)) = √(2653.98547/(9-2)) = 19.4715
Slope, b = SSxy/SSxx = 1568.44444/2018.22222 = 0.777141599
y-intercept, a = y̅ -b* x̅ = 73.11111 - (0.77714)*78.55556 = 12.06232107
Regression equation :
ŷ = 12.0623 + (0.7771) x
Predicted value of y at x = 85
ŷ = 12.0623 + (0.7771) * 85 = 78.1194
Significance level, α = 0.05
Critical value, t_c = T.INV.2T(0.05, 7) = 2.3646
95% Confidence interval :
Lower limit = ŷ - tc*se*√((1/n) + ((x-x̅)²/(SSxx)))
= 78.1194 - 2.3646*19.4715*√((1/9) + ((85 - 78.5556)²/(2018.2222))) = 61.411
Upper limit = ŷ + tc*se*√((1/n) + ((x-x̅)²/(SSxx)))
= 78.1194 + 2.3646*19.4715*√((1/9) + ((85 - 78.5556)²/(2018.2222))) = 94.828