Simple Linear Regression

3 minutes
Share the link to this page
Copied
  Completed
You need to have access to the item to view this lesson.
One-time Fee
$49.99
List Price:  $69.99
You save:  $20
€44.05
List Price:  €61.68
You save:  €17.62
£37.58
List Price:  £52.62
You save:  £15.03
CA$69.44
List Price:  CA$97.22
You save:  CA$27.78
A$78.41
List Price:  A$109.78
You save:  A$31.37
S$65.75
List Price:  S$92.05
You save:  S$26.30
HK$387.76
List Price:  HK$542.90
You save:  HK$155.13
CHF 41.54
List Price:  CHF 58.16
You save:  CHF 16.61
NOK kr522.97
List Price:  NOK kr732.21
You save:  NOK kr209.23
DKK kr328.90
List Price:  DKK kr460.49
You save:  DKK kr131.58
NZ$83.99
List Price:  NZ$117.60
You save:  NZ$33.60
د.إ183.61
List Price:  د.إ257.07
You save:  د.إ73.46
৳6,091.40
List Price:  ৳8,528.46
You save:  ৳2,437.05
₹4,271.75
List Price:  ₹5,980.80
You save:  ₹1,709.04
RM218.65
List Price:  RM306.13
You save:  RM87.48
₦80,730.85
List Price:  ₦113,029.65
You save:  ₦32,298.80
₨14,091.30
List Price:  ₨19,728.96
You save:  ₨5,637.65
฿1,677.91
List Price:  ฿2,349.21
You save:  ฿671.30
₺1,920.75
List Price:  ₺2,689.20
You save:  ₺768.45
B$284.04
List Price:  B$397.68
You save:  B$113.64
R945.21
List Price:  R1,323.38
You save:  R378.16
Лв86.13
List Price:  Лв120.59
You save:  Лв34.45
₩71,921.98
List Price:  ₩100,696.53
You save:  ₩28,774.54
₪180.85
List Price:  ₪253.20
You save:  ₪72.35
₱2,814.26
List Price:  ₱3,940.19
You save:  ₱1,125.93
¥7,179.56
List Price:  ¥10,051.96
You save:  ¥2,872.40
MX$983.64
List Price:  MX$1,377.18
You save:  MX$393.53
QR182.75
List Price:  QR255.87
You save:  QR73.11
P686.29
List Price:  P960.87
You save:  P274.57
KSh6,463.70
List Price:  KSh9,049.70
You save:  KSh2,586
E£2,547.49
List Price:  E£3,566.69
You save:  E£1,019.20
ብር6,681.17
List Price:  ብር9,354.18
You save:  ብር2,673
Kz45,590.88
List Price:  Kz63,830.88
You save:  Kz18,240
CLP$46,812.37
List Price:  CLP$65,541.06
You save:  CLP$18,728.69
CN¥364.27
List Price:  CN¥510.01
You save:  CN¥145.74
RD$2,975.10
List Price:  RD$4,165.38
You save:  RD$1,190.28
DA6,619.03
List Price:  DA9,267.17
You save:  DA2,648.14
FJ$112.99
List Price:  FJ$158.20
You save:  FJ$45.20
Q386.10
List Price:  Q540.58
You save:  Q154.47
GY$10,489.05
List Price:  GY$14,685.51
You save:  GY$4,196.46
ISK kr6,375.22
List Price:  ISK kr8,925.82
You save:  ISK kr2,550.60
DH464.99
List Price:  DH651.02
You save:  DH186.03
L862.86
List Price:  L1,208.08
You save:  L345.21
ден2,708.74
List Price:  ден3,792.46
You save:  ден1,083.71
MOP$400.53
List Price:  MOP$560.77
You save:  MOP$160.24
N$935.59
List Price:  N$1,309.90
You save:  N$374.31
C$1,838.46
List Price:  C$2,573.99
You save:  C$735.53
रु6,841.02
List Price:  रु9,577.98
You save:  रु2,736.95
S/185.02
List Price:  S/259.04
You save:  S/74.02
K207.50
List Price:  K290.52
You save:  K83.01
SAR187.51
List Price:  SAR262.53
You save:  SAR75.02
ZK1,410.01
List Price:  ZK1,974.13
You save:  ZK564.11
L219.29
List Price:  L307.02
You save:  L87.73
Kč1,100.07
List Price:  Kč1,540.19
You save:  Kč440.12
Ft17,940.87
List Price:  Ft25,118.65
You save:  Ft7,177.78
SEK kr485.01
List Price:  SEK kr679.06
You save:  SEK kr194.04
ARS$58,712.48
List Price:  ARS$82,202.17
You save:  ARS$23,489.69
Bs346.41
List Price:  Bs485.01
You save:  Bs138.59
COP$215,920.08
List Price:  COP$302,305.39
You save:  COP$86,385.31
₡25,270.56
List Price:  ₡35,380.81
You save:  ₡10,110.24
L1,299.69
List Price:  L1,819.68
You save:  L519.98
₲401,259.06
List Price:  ₲561,794.79
You save:  ₲160,535.73
$U2,086.69
List Price:  $U2,921.54
You save:  $U834.84
zł188.24
List Price:  zł263.56
You save:  zł75.31
Already have an account? Log In

Transcript

Okay for this simple linear regressions. So in our high school we learn about linear regression, the formula is y equals mx plus C. In University, the formula is y equals alpha plus beta X. So to find L bar, we can use the y bar y bar is the mean of Y minus beta times the x bar x bar is the mean of x. To find that beta, we can use something like this our si minus x bar times y minus y bar, and then we do the summation divided by the summation of si minus S bar the mean of x and then we square the whole thing. So this is the formula to let's say, calculate alpha and beta for the simple linear regression equations. So, as I mentioned previously, prediction model is to predict numerical variable classification model is to predict a categorical variable.

So let's say we have a training data data set, we try to split this data into our training data and testing data. So we can split this data set using let's say, our sampling method 75% for training data and 25% for testing data. Then we These are 770 5% training data, we can use these training data to train our linear regressions. So we can use this training data to calculate the beta and the alpha. So after we use the training data to Car train these linear regression model we get is a linear regression equation which is a price equal minus seven 0.1 plus one pi 6.9 times the engine size. So, this will be the alpha.

So the alpha So, this will be the alpha, beta beta times the engine. So, we use the training data to train the linear regression model. And we get all these Alpine all this data for our simple linear regression equations. So, with these simple linear regression equation or model, we can actually use this equation to predict the price was from let's say a new data set or from the testing dataset. So this is a simple linear regressions

Sign Up

Share

Share with friends, get 20% off
Invite your friends to LearnDesk learning marketplace. For each purchase they make, you get 20% off (upto $10) on your next purchase.