Skip to content

Samuel-the-crack/Real-Estate-Simple-Linear-Regression

Repository files navigation

Real-Estate-Simple-Linear-Regression

This is a basic implementation of simple linear regression

Simple Linear Regression Using OLS (Ordinary Least Square)

This is the code implementation of simple linear regression. In this code I'm using python's statsmodel module to implement OLS (Ordinary Least Square) method of linear regression, for complete information aobut statsmodel's OLS, I suggest to visit This Link.

Requirements : Numpy, Pandas, Matplotlib, Statsmodel

Overview

This code is using 'real_estate_price_size.csv' as an input (I enclose the file in this repository). After importing the csv data usisng pandas I'm declaring the dependent and the independent variables wich are Price and Size. Since the variable declared I'm doing the regression with statsmodel and then visualizing it with matplotlib scatter and draw the regression line within.

Releases

No releases published

Packages

No packages published