← Statistics for Data Science learning pathStatistics for Data Science · Module 8 of 10
Correlation and regression
Measure relationships and predict values.
📖 Key ideas
- Correlation (r) ranges from −1 to 1.
- Linear regression fits y = a + b·x.
- Slope b shows change in y per unit x.
- R² shows the share of variance explained.
- Check residuals for patterns and outliers.
💡 Real-life example: Regression draws the best road through scattered houses, showing the general direction.
Correlation coefficientStrength and direction of linear relation
SlopeChange in y per unit x
R-squaredVariance explained
ResidualActual minus predicted