Simple Linear Regression (Slope)
Predicted change in Y for a 1-unit change in X.
This public page keeps the free explanation visible and leaves premium worked solving, advanced walkthroughs, and saved study tools inside the app.
Core idea
Overview
In simple linear regression, the slope coefficient represents the expected change in the dependent variable for every one-unit increase in the independent variable. This specific formula calculates the slope by adjusting the Pearson correlation coefficient based on the ratio of the variability in the outcome variable to the variability in the predictor.
When to use: This formula is used when you need to establish a predictive relationship between two continuous variables and have already calculated their correlation and standard deviations. It is appropriate when the relationship between variables is linear and you wish to determine the unstandardized effect size in raw units.
Why it matters: In psychological research, understanding the slope allows clinicians and scientists to quantify the impact of variables, such as how much a patient's anxiety score might decrease for every hour of therapy completed. It provides a more practical, unit-based interpretation of data than correlation alone.
Symbols
Variables
b = Slope (b), r = Correlation, SD_y = SD of Y, SD_x = SD of X
Walkthrough
Derivation
Formula: Simple Linear Regression (Slope)
Formula for the slope of the line of best fit.
- Linear relationship.
- Homoscedasticity.
Calculate slope b:
Based on the correlation r and the relative spread of y and x scores.
Result
Source: University Psychology — Statistics
Free formulas
Rearrangements
Solve for
Make b the subject
The slope 'b' is given by the correlation 'r' multiplied by the ratio of the standard deviation of Y to the standard deviation of X.
Difficulty: 1/5
Solve for
Make r the subject
The correlation 'r' is calculated by multiplying the slope 'b' by the standard deviation of X and then dividing by the standard deviation of Y.
Difficulty: 2/5
Solve for
Make SDy the subject
The standard deviation of Y 'SDy' is found by multiplying the slope 'b' by the standard deviation of X 'SDx' and then dividing by the correlation 'r'.
Difficulty: 2/5
Solve for
Make SDx the subject
The standard deviation of X 'SDx' is obtained by multiplying the correlation 'r' by the standard deviation of Y 'SDy' and then dividing by the slope 'b'.
Difficulty: 2/5
The static page shows the finished rearrangements. The app keeps the full worked algebra walkthrough.
Visual intuition
Graph
Graph unavailable for this formula.
The graph is a constant horizontal line because the slope (b) is a fixed value derived from the correlation and standard deviations of the variables. Since the formula calculates a single scalar coefficient, the Y-axis value remains unchanged regardless of the independent variable plotted on the X-axis.
Graph type: constant
Why it behaves this way
Intuition
Imagine a scatterplot of data points, where a straight line is drawn to best fit the overall trend. The slope 'b' represents how steeply this line rises or falls, indicating the average vertical change for every one-unit
Signs and relationships
- r: The sign of the slope 'b' is directly determined by the sign of the Pearson correlation coefficient 'r'. If 'r' is positive, 'b' will be positive, indicating that as X increases, Y tends to increase.
Free study cues
Insight
Canonical usage
The slope coefficient 'b' will have units corresponding to the ratio of the units of the dependent variable (Y) to the independent variable (X), while the Pearson correlation coefficient 'r' is dimensionless.
Common confusion
Students often forget that the slope 'b' has units, unlike the correlation coefficient 'r', and misinterpret its magnitude without considering the scales of X and Y.
Dimension note
The Pearson correlation coefficient ('r') is inherently dimensionless, as it is a ratio of covariation to the product of standard deviations.
Unit systems
One free problem
Practice Problem
A psychologist finds that the correlation between weekly exercise hours (X) and subjective well-being scores (Y) is 0.50. If the standard deviation of well-being scores is 12 and the standard deviation of exercise hours is 2, calculate the regression slope.
Solve for:
Hint: Divide the standard deviation of Y by the standard deviation of X, then multiply by the correlation.
The full worked solution stays in the interactive walkthrough.
Where it shows up
Real-World Context
Predicting exam performance from hours of sleep.
Study smarter
Tips
- The sign of the slope (b) will always be the same as the sign of the correlation coefficient (r).
- If the standard deviations of both variables are equal, the slope is exactly equal to the correlation coefficient.
- Always ensure the predictor (SDx) is the denominator in the fraction to avoid inverse scaling errors.
Avoid these traps
Common Mistakes
- Swapping SDx and SDy.
- Extrapolating outside the data range.
Common questions
Frequently Asked Questions
Formula for the slope of the line of best fit.
This formula is used when you need to establish a predictive relationship between two continuous variables and have already calculated their correlation and standard deviations. It is appropriate when the relationship between variables is linear and you wish to determine the unstandardized effect size in raw units.
In psychological research, understanding the slope allows clinicians and scientists to quantify the impact of variables, such as how much a patient's anxiety score might decrease for every hour of therapy completed. It provides a more practical, unit-based interpretation of data than correlation alone.
Swapping SDx and SDy. Extrapolating outside the data range.
Predicting exam performance from hours of sleep.
The sign of the slope (b) will always be the same as the sign of the correlation coefficient (r). If the standard deviations of both variables are equal, the slope is exactly equal to the correlation coefficient. Always ensure the predictor (SDx) is the denominator in the fraction to avoid inverse scaling errors.
References
Sources
- Gravetter, F. J., Wallnau, L. B., Forzano, L. B. (2018). Statistics for the Behavioral Sciences (10th ed.). Cengage Learning.
- Wikipedia: Simple linear regression
- Field, A. (2018). Discovering statistics using IBM SPSS Statistics (5th ed.). SAGE Publications.
- Gravetter, F. J., Wallnau, L. B., Forzano, L. B., & Witnauer, J. E. (2021). Essentials of statistics for the behavioral sciences (10th ed.).
- Wikipedia: Pearson correlation coefficient
- Wikipedia: Standard deviation
- Howell, D. C. (2013). Statistical Methods for Psychology (8th ed.). Wadsworth Cengage Learning.
- University Psychology — Statistics