Understanding a simple linear regression model and its rich content
Simple linear regression is the simplest regression model. You only have two variables: one dependent variable, usually denoted by y, and an independent variable, usually denoted by x. The relationship is linear, so the model only contains two parameters. The relationship can be formulated with the following formula:
k is the slope and b is the intercept. Є is the noise term.
Note
Proportionality is different from linearity. Proportionality implies linearity and it is a stronger requirement that b must be 0 in the formula. Linearity, graphically, means that the relationship between two variables can be represented as a straight, but strict mathematical requirement of additivity and homogeneity. If a relationship (function f) is linear, then for any input x1 and x2 and scaler k, we must have the following equations: and .
Here is the code snippet that utilizes the yfinance
library to obtain Netflix...