📊

Linear Regression for Apartment Rent

Jul 26, 2025

Overview

This lecture explains how to use square footage to predict monthly rent for apartments in Queens, NY, using linear regression analysis.

Identifying Variables

  • The X variable (explanatory) is square footage.
  • The Y variable (response) is monthly rent.
  • X is what you use to predict; Y is what you want to predict.

Creating a Scatter Plot

  • Square footage is plotted on the X-axis; monthly rent on the Y-axis.
  • The scatter plot appears linear, suggesting a linear relationship.

Calculating the Correlation Coefficient (r)

  • Enter square footage data in List 1 and rent in List 2 on your calculator.
  • Use the calculator's LinReg(a+bx) function under Stat > Calc > Option 8.
  • The calculated r value is 0.909, indicating a strong positive linear relationship.

Regression Equation & Prediction

  • LinReg(a+bx) provides the regression equation: y = -34.31 + 2.21x.
  • This equation fits the data points well and can be used for predictions.
  • To predict rent for a 995 sq ft apartment, plug 995 into the equation: y = -34.31 + 2.21(995) = $2164.64.

Key Terms & Definitions

  • Explanatory Variable (X) — the input variable used to make predictions (here, square footage).
  • Response Variable (Y) — the outcome you want to predict (here, monthly rent).
  • Scatter Plot — graph showing relationship between two variables.
  • Correlation Coefficient (r) — measures strength and direction of linear relationship between variables.
  • Linear Regression — statistical method to model and predict the relationship between two variables.
  • Regression Equation — formula predicting Y from X; here, y = -34.31 + 2.21x.

Action Items / Next Steps

  • Complete the calculation for predicted rent with other square footage values.
  • Review calculator functions: entering data, creating scatter plots, performing linear regression.
  • Practice identifying X and Y variables in other prediction problems.