---
title: "Twists regression; CI for slope"
subject: "Probability and Statistics"
chapter: 5
key: "semester_5/probability_and_statistics:twists-regression-with-ci-slope"
source: https://www.bctengineer.com/q/semester_5/probability_and_statistics/twists-regression-with-ci-slope
site: BCT Engineering
---

# Twists regression; CI for slope

Probability and Statistics · Chapter 5: Correlation and regression

- Asked in: 2071 Chaitra, 5 marks; 2075 Asoj, 4 marks (asked 2 times)
- Answer checked by Claude Sonnet 5.5 on 2026-10-14
- Page: https://www.bctengineer.com/q/semester_5/probability_and_statistics/twists-regression-with-ci-slope
- Whole chapter: https://www.bctengineer.com/md/semester_5/probability_and_statistics/chapter-5

## Question

The following data gives the number of twists required to break a certain kind of forged alloy bar and percentage of alloying element A present in the metal.
| Number of twists | 41 | 49 | 69 | 65 | 40 | 50 | 58 | 57 | 31 | 36 |
|---|---|---|---|---|---|---|---|---|---|---|
| Percentage of element A | 10 | 12 | 14 | 15 | 13 | 12 | 13 | 14 | 13 | 12 |
i) Fit the regression equation of number of twists on percentage of element A. Determine the predicted number of twists required to break an alloy when percentage of element is 20.
ii) Find 99% confidence interval for the regression coefficient (i.e. slope).

## Short answer

Fitted equation: ŷ = -21.091 + 5.523x; at 20% element A, predicted twists ≈ 89. The 99% CI for slope is (-2.959, 14.004) using t(0.005,8)=3.355 and SE=2.5277.

## Answer

Let x = percentage of element A (independent), y = number of twists (dependent).

#### i) Regression of y on x

Sums (n = 10):

```text
        x        y       xy       x²       y²
       10       41      410      100     1681
       12       49      588      144     2401
       14       69      966      196     4761
       15       65      975      225     4225
       13       40      520      169     1600
       12       50      600      144     2500
       13       58      754      169     3364
       14       57      798      196     3249
       13       31      403      169      961
       12       36      432      144     1296
---------------------------------------------
      128      496     6446     1656    26038
```

Σx = 128, Σy = 496, Σxy = 6446, Σx² = 1656, Σy² = 26038

Means: x̄ = 12.8000, ȳ = 49.6000

Sxx = Σx² − (Σx)²/n = 17.6000
Sxy = Σxy − (Σx)(Σy)/n = 97.2000
Syy = Σy² − (Σy)²/n = 1436.4000

Slope b = Sxy/Sxx = 97.2000/17.6000 = 5.5227
Intercept a = ȳ − bx̄ = 49.6000 − (5.5227)(12.8000) = -21.0909

Regression equation: **ŷ = -21.091 + 5.523 x**

Prediction at x = 20: ŷ = -21.0909 + 5.5227(20) = 89.36 ≈ **89 twists**.

(Note: x = 20 lies outside the observed range 10–15, so this is an extrapolation and less reliable.)

#### ii) 99% confidence interval for the slope β

β̂ ± t(α/2, n−2) · SE(b), where SE(b) = s/√Sxx and s² = SSE/(n − 2).

- SSE = Syy − b·Sxy = 1436.4000 − (5.5227)(97.2000) = 899.5909
- s² = SSE/(n − 2) = 899.5909/8 = 112.4489, s = 10.6042
- SE(b) = √(112.4489/17.6000) = 2.5277
- t(0.005, 8) = 3.355

b ± t·SE(b) = 5.5227 ± (3.355)(2.5277) = 5.5227 ± 8.4813

**99% CI for β: (-2.959, 14.004).**

Since the interval contains 0, the slope is not significantly different from zero at the 1% level.

## Check yourself

The answer's key points as multiple-choice questions, with the correct option and why.

1. Predicting twists at x = 20 (observed x is 10 to 15) is:
   A. Interpolation and very reliable
   B. Extrapolation, so less reliable
   C. Impossible with regression
   D. Reliable because r = 1
   Answer: B. 20 lies outside the data range 10–15, so the prediction (about 89) is an extrapolation. (Key point: Prediction and extrapolation)

2. How is s² for the slope's standard error obtained?
   A. SSE/n
   B. Syy/(n − 1)
   C. SSE/(n − 2) with SSE = Syy − b·Sxy
   D. Sxy/Sxx
   Answer: C. s² = SSE/(n − 2) = 899.59/8 = 112.45, with SSE = Syy − b·Sxy. (Key point: Residual variance)

3. For a 99% CI for the slope with n = 10, the t value is:
   A. t(0.005, 9) = 3.250
   B. t(0.01, 10) = 2.764
   C. t(0.005, 8) = 3.355
   D. z = 2.576
   Answer: C. The slope CI uses n − 2 = 8 degrees of freedom and α/2 = 0.005, giving 3.355. (Key point: t value for CI)

4. The 99% CI for the slope is (−2.959, 14.004). What does it show?
   A. The slope is significantly positive
   B. The slope is exactly 5.52
   C. The slope is negative
   D. It contains 0, so the slope is not significantly different from zero at the 1% level
   Answer: D. Since 0 lies inside the interval, we cannot conclude a linear effect at the 1% level. (Key point: Interpreting the CI)

## Close variants set in other exams

- [Twists regression; predict at 20%](https://www.bctengineer.com/question.md?key=semester_5%2Fprobability_and_statistics%3Atwists-regression-predict-20) — Probability and Statistics, chapter 5, asked 3×
