What is simple linear regression
Linear regression is a machine learning algorithm more specifically in supervised learning algorithm that learns from labelled dataset and maps the data points in most optimized linear function which can be used prediction for data
Linear regression solve only regression porblems with numerical or continuous value based on dependent feature(target) and one or more independent features
For example house price dataset where dependent feature is price and independent features are area,sqft, bedroom
Linear regression equation is y= mx+c
Where y= dependent variable
X=independent variables
M = intercept
C= slope
Intercept and slope also known as weight and bias in context of deep learning
What exactly do intercept and slope in LR?
Intercept is value of dependent variable when independent variable is zero. It represents the starting point of value y when x=0
Ex:- use House price when intercept is 50,000
This means when a house is 0 sqft the base line is 50,000(hypothetically). In practice it gives the baseline value when independent features are minimal or no impact
Slope represents rate of change in dependent feature with respect to independent features . In simple words it tells you how much dependent variable change when you change independent variables by 1 unit
If slope is postive both independent and dependent variable are increases while if slope is negetive only independent features are increases other decreases
Main aim of slope and intercept is together to conclude the best fit line in linear regression
Comments
Post a Comment