Professional Documents
Culture Documents
STA 201
S M Rajib Hossain
Lecture-8
Regression Analysis
For example,
✓ Dependent variables.
✓ Independent variables.
✓
✓ y is the predicted value of the dependent variable for any given value
of the independent variable (x).
✓ 𝛼 is the intercept, the predicted value of y when the x is 0.
✓ 𝛽 is the regression coefficient (slope) – how much we expect y to
change as x increases.
✓ x is the independent variable (the variable we expect is influencing y).
Estimated/fitted equation is 𝑦̂ = 𝛼̂ + 𝛽̂ 𝑥
𝑛
∑ 𝑥 𝑦 −𝑛𝑥̅ 𝑦̅
Here, 𝛽̂ = ∑1𝑛 𝑖 2𝑖 2
1 𝑥𝑖 −𝑛𝑥̅
𝛼̂ = 𝑦̅ − 𝛽̂ 𝑥̅
Solution:
𝑥𝑖 𝑦𝑖 𝑥𝑖 𝑦𝑖 𝑥𝑖 2
2 60 120 4
3 70 210 9
4 75 300 16
5 80 400 25
6 85 510 36
∑𝑛1 𝑥𝑖 =20 ∑𝑛1 𝑦𝑖 =370 ∑𝑛1 𝑥𝑖 𝑦𝑖 =1540 ∑𝑛1 𝑥𝑖 2 =90
∑𝑛
1 𝑥𝑖 ∑𝑛
1 𝑦𝑖
Here, 𝑥̅ = 𝑦̅ =
𝑛 𝑛
20 370
= =
5 5
=4 = 74
𝑛
∑ 𝑥 𝑦 −𝑛𝑥̅ 𝑦̅
We know, 𝛽̂ = ∑1𝑛 𝑖 2𝑖 2 𝛼̂ = 𝑦̅ − 𝛽̂ 𝑥̅
1 𝑥𝑖 −𝑛𝑥̅
1540−5∗4∗74
= = 74- 6*4
90−5∗4 2
=6 = 50
Fitted equation is 𝑦̂ = 50 + 6𝑥
Interpretation:
✓ The slope (𝛽̂ = 6) indicates that, on average, for each additional hour
of study, the exam score is expected to increase by approximately 6
points.
✓ The intercept (𝛼̂ = 50) suggests that if a student doesn't study at all (0
hours), their expected exam score is around 50.
𝑦̂ = 50 + 6 ∗ 8
= 98
So, the predicted exam score is 98.