Fit a straight line between one predictor (X) and a response (Y): the equation, how much of the variation it explains, whether the slope is real, and the residual checks.
More than one predictor? Multiple Regression
| # | |||
|---|---|---|---|
| 1 | |||
| 2 | |||
| 3 | |||
| 4 | |||
| 5 | |||
| 6 | |||
| 7 | |||
| 8 | |||
| 9 | |||
| 10 | |||
| 11 |
Simple linear regression fits a straight line between one input X (for example temperature, pressure, time) and one result Y (strength, thickness, yield). It tells you how much Y changes for each unit of X, whether that relationship is real or could be chance, and what Y to expect at a setting you have not tried.
A strong relationship does not prove that X causes Y. Use data from a controlled trial when you can, and check the residual plots before you rely on the line.
Ordinary least squares, with exact p-values for each coefficient and for the model, R², adjusted R² and predicted R², residual checks with plots, unusual observations, and confidence and prediction intervals for a new setting. The calculation reproduces the certified values of the NIST reference data sets.
The data behind “Try an example”: tensile strength measured at 11 temperatures from 120 to 170.
| Result | Value |
|---|---|
| Equation | Strength = 14.953 + 0.27236 × Temperature |
| p-value of the slope | < 0.001 |
| R² · R²(pred) | 99.18% · 98.80% |
| Prediction at 158 | 57.99 · 95% PI 56.93 to 59.04 |
Each extra degree adds about 0.27 to the strength, the residuals pass the checks, and the line predicts new points almost as well as it fits these ones. A single new part made at 158 should measure between 56.93 and 59.04 in 95% of cases.