Univariate linear regression: concrete compressive strength

Explore how the intercept and slope influence a regression line. Each point is a real concrete-mixture observation with 28-day compressive strength as the target. Cement content is the only input feature.

Adjust the line, then compare it with the ordinary least-squares fit.

Input cement: 298.2 kg/m³Prediction: Training MSE: hiddenHeld-out residual: not revealed
Training dataPrediction lineTraining residualsHeld-out observation
Think about it: Why can concrete mixtures with the same cement content have different strengths? Which additional features might improve the predictions?

Source: Yeh (1998), Concrete Compressive Strength, UCI Machine Learning Repository, DOI: 10.24432/C5PK67, CC BY 4.0. The training records are drawn from the dataset; one observation was withheld from fitting. The fitted line is a teaching model, not a concrete-design equation. Once the held-out target is used to tune a model, it no longer serves as independent test evidence.