NivaarExam PrepOfficial exam papers ↗

04-BS-2 · December 2019

Question 8 of 8: Electric Consumption vs. Residence Area (Correlation and Regression)

Nivaar worked solution (AI-drafted; not reviewed by a licensed engineer)

Notes on this paper

National Examinations December 2019 — 04-BS-2, Probability and Statistics, 2 hours, closed book except one hand-written information sheet and an approved calculator. Any 5 of 8 questions constitute a complete paper; all 8 are solved below.

Reference texts: Walpole, Myers, Myers & Ye, Probability & Statistics for Engineers and Scientists (Pearson) — used throughout for distribution theory, estimation and hypothesis-testing formulas.

Question 8: Electric Consumption vs. Residence Area (Correlation and Regression) (20 marks)

Question text not reproduced: the examination questions are © Engineers and Geoscientists BC. Open the official past paper (linked at the top of this page) to read the question, then follow the worked solution below.

Given. n=39, $\Sigma X=1{,}092.0$, $\Sigma X^2=31{,}944.0$, $\Sigma Y=312.0$, $\Sigma Y^2=2{,}534.0$, $\Sigma XY=8{,}926.0$.

Given data
nΣXΣX²ΣYΣY²ΣXY
391,092.031,944.0312.02,534.08,926.0

Find. (a) cov(X,Y) and r. (b) 95% CI for ρ. (c) the normal equations and least-squares estimates $b_0,b_1$. (d) SSE and the 95% CI for $\beta_1$.

Approach. Reduce the raw sums to the corrected sums of squares/cross-products $S_{xx}, S_{yy}, S_{xy}$, which drive every downstream quantity: covariance, r, the Fisher-z CI for ρ, the least-squares slope/intercept, and the CI for the slope.

  1. Corrected sums of squares/products. $$\bar X=\dfrac{1092.0}{39}=28.0, \qquad \bar Y=\dfrac{312.0}{39}=8.0$$ $$S_{xx}=\Sigma X^2-n\bar X^2=31944.0-39(28.0)^2=1368.0$$ $$S_{yy}=\Sigma Y^2-n\bar Y^2=2534.0-39(8.0)^2=38.0$$ $$S_{xy}=\Sigma XY-n\bar X\bar Y=8926.0-39(28.0)(8.0)=190.0$$
  2. (a)(i)–(ii) Covariance and correlation coefficient. $$\text{cov}(X,Y)=\dfrac{S_{xy}}{n-1}=\dfrac{190.0}{38}=5.0$$ $$r=\dfrac{S_{xy}}{\sqrt{S_{xx}S_{yy}}}=\dfrac{190.0}{\sqrt{1368.0(38.0)}}=\dfrac{190.0}{228.0}$$ $$\boxed{\text{cov}(X,Y)=5.0, \qquad r=0.8333}$$
  3. (b) 95% CI for ρ via the Fisher z-transformation. $$z_r=\tfrac12\ln\!\left(\dfrac{1+r}{1-r}\right)=\tfrac12\ln\!\left(\dfrac{1.8333}{0.1667}\right)=1.1989, \qquad \text{SE}=\dfrac{1}{\sqrt{n-3}}=\dfrac{1}{\sqrt{36}}=0.1667$$ $$z_r\pm1.96(0.1667)=1.1989\pm0.3267 \ \Rightarrow\ (0.8722,\,1.5256)$$ Converting back via $r=\dfrac{e^{2z}-1}{e^{2z}+1}$: $$\boxed{0.703\lt\rho\lt0.910}$$
  4. (c) Normal equations and least-squares estimates. The least-squares normal equations for $Y=b_0+b_1X$ are $$\Sigma Y=nb_0+b_1\Sigma X, \qquad \Sigma XY=b_0\Sigma X+b_1\Sigma X^2$$ Solving (equivalently, using the corrected sums directly): $$b_1=\dfrac{S_{xy}}{S_{xx}}=\dfrac{190.0}{1368.0}=0.1389, \qquad b_0=\bar Y-b_1\bar X=8.0-0.1389(28.0)$$ $$\boxed{b_1=0.1389, \qquad b_0=4.111}$$
  5. (d) Error sum of squares and 95% CI for β1. $$\text{SSE}=S_{yy}-b_1S_{xy}=38.0-0.1389(190.0)=11.611$$ $$s^2=\dfrac{\text{SSE}}{n-2}=\dfrac{11.611}{37}=0.3138, \qquad \text{SE}(b_1)=\dfrac{s}{\sqrt{S_{xx}}}=\dfrac{0.5602}{\sqrt{1368.0}}=0.01514$$ With $t_{0.025,37}\approx2.026$: $$b_1\pm t_{0.025,37}\,\text{SE}(b_1)=0.1389\pm2.026(0.01514)=0.1389\pm0.0307$$ $$\boxed{0.108\lt\beta_1\lt0.170}$$
Question 8 — summary of results
PartQuantityResult
(a)(i)cov(X,Y)5.0
(a)(ii)r0.8333
(b)95% CI for ρ(0.703, 0.910)
(c)b0, b14.111, 0.1389
(d)SSE; 95% CI for β111.611; (0.108, 0.170)