Overview
Use linear regression to describe how one variable depends on one or more others, and to predict new values from them. For example, a child’s height depends on their age, so height is the dependent variable and age the independent (predictor) variable. The reverse is not true: age does not depend on height.
This dependence is what distinguishes regression from correlation, which measures how closely two variables vary together without either one depending on the other.
Casewise residuals, leverage and Cook’s distance help to identify outliers and to check the assumptions of the model.
Comparing regressions tests for differences between the slopes of two or more regression lines and, where the slopes don’t differ, between their elevations, with multiple comparison tests to show which lines differ. When slopes do differ, elevations can be compared at an X value you choose.
Methods
- Simple linear regression
- Regression through the origin
- Multiple regression
- Forward and backward stepwise regression
- Polynomial regression
- Weighted regression
- Comparing slopes and elevations of regressions
- Residual diagnostics (studentised residuals, leverage, Cook's distance)
- Normal probability, residual and partial regression plots
- Confidence and prediction bands
Running the analysis
Click Regression on the statistiXL ribbon and choose Linear Regression or Compare Linear Regressions. In the dialog, select your Y and X variable ranges, any weights and the output location. The Options and Plots pages set the variable selection method, casewise statistics and plots.


What the output includes
The output depends on whether you fit a regression or compare regression lines.
Linear regression
- Descriptive statistics and a correlation matrix (optional)
- A summary with R², R, adjusted R² and the standard error of the estimate
- The ANOVA table, with F and P for the regression
- Regression coefficients, with standard errors, standardised coefficients, 95% confidence limits, t and P
- Each step of a stepwise regression (optional)
- Casewise residuals, leverage and Cook's distance (optional)
- Normal probability, residual, scatter and partial regression plots (optional)
Comparing regressions
- The regression results for each line (optional)
- Tests for differences between the slopes and, where the slopes don't differ, the elevations
- Multiple comparison tests showing which slopes or elevations differ (optional)
- A scatter plot of all the regressions (optional)
