⏳ Loading example…
📊
Multiple Reg.
Multiple Regression — Predict Exam Score from Study & Sleep Hours
Two-predictor OLS regression. Normal equations, β weights (b₁=3.39, b₂=2.57), R²=.973, F(2,7)=125.2.
📊 R² = .973, F(2,7) = 125.2, p < .001
Step-by-step solution
📊 14 · Multiple Linear Regression
Predict Exam Score from Study Hours + Sleep Hours
Multiple Regression
Research Question:
Can weekly study hours (X₁) and nightly sleep hours (X₂) together predict exam scores (Y) in a sample of 10 students?
| Student | X₁ (Study hrs) | X₂ (Sleep hrs) | Y (Score) | Ŷ | e = Y−Ŷ |
|---|---|---|---|---|---|
| 1 | 4 | 6 | 58 | 55.3 | 2.7 |
| 2 | 6 | 7 | 64 | 64.7 | −0.7 |
| 3 | 8 | 8 | 72 | 74.0 | −2.0 |
| 4 | 5 | 5 | 55 | 56.1 | −1.1 |
| 5 | 9 | 8 | 78 | 77.4 | 0.6 |
| 6 | 7 | 7 | 70 | 68.1 | 1.9 |
| 7 | 10 | 9 | 85 | 83.4 | 1.6 |
| 8 | 3 | 6 | 52 | 51.9 | 0.1 |
| 9 | 8 | 6 | 68 | 68.9 | −0.9 |
| 10 | 6 | 8 | 65 | 67.2 | −2.2 |
| x̄ | 6.6 | 7.0 | 66.7 |
OLS Normal Equations (2 predictors)
$$S_{x_1x_1}=44.4,\quad S_{x_2x_2}=14.0,\quad S_{x_1x_2}=18.0$$
$$S_{yx_1}=196.8,\quad S_{yx_2}=97.0$$
$$b_1=\frac{S_{yx_1}S_{x_2x_2}-S_{yx_2}S_{x_1x_2}}{S_{x_1x_1}S_{x_2x_2}-S_{x_1x_2}^2}=\frac{196.8\times14-97.0\times18}{44.4\times14-18^2}=\frac{1009.2}{297.6}=\mathbf{3.39}$$
$$b_2=\frac{S_{yx_2}S_{x_1x_1}-S_{yx_1}S_{x_1x_2}}{297.6}=\frac{764.4}{297.6}=\mathbf{2.57}$$
$$b_0=\bar{Y}-b_1\bar{X}_1-b_2\bar{X}_2=66.7-3.39(6.6)-2.57(7.0)=\mathbf{26.34}$$
$$\hat{Y}=26.34+3.39X_1+2.57X_2$$
| Predictor | b | SE | t | p | 95% CI | β (std) |
|---|---|---|---|---|---|---|
| Intercept | 26.34 | 4.18 | 6.30 | <.001 | [17.1, 35.6] | — |
| Study Hours (X₁) | 3.39 | 0.41 | 8.27 | <.001 | [2.4, 4.4] | .74 |
| Sleep Hours (X₂) | 2.57 | 0.74 | 3.47 | .010 | [0.9, 4.2] | .32 |
R², Adjusted R², F
$$SS_{tot}=942.1,\quad SS_{res}=25.6,\quad SS_{reg}=916.5$$
$$R^2=\frac{916.5}{942.1}=\mathbf{.973},\quad R^2_{adj}=1-\frac{25.6/7}{942.1/9}=\mathbf{.965}$$
$$F(2,7)=\frac{916.5/2}{25.6/7}=\frac{458.3}{3.66}=\mathbf{125.2},\quad p<.001$$
.973
R²
.965
Adj R²
125.2
F(2,7)
<.001
p
✅ The two-predictor model explains 97.3% of variance. Each extra study hour adds 3.39 points; each extra sleep hour adds 2.57 points.
APA-7
Multiple linear regression was used to predict exam scores from study hours and sleep hours. The overall model was statistically significant, F(2, 7) = 125.2, p < .001, R² = .973, adjusted R² = .965. Study hours (b = 3.39, SE = 0.41, β = .74, t(7) = 8.27, p < .001) and sleep hours (b = 2.57, SE = 0.74, β = .32, t(7) = 3.47, p = .010) were both significant predictors.