mpg = mileage per gallon and hp = horsepower
Why is this model a linear model despite having a square of horsepower in it?
Cross Validated is a question and answer site for people interested in statistics, machine learning, data analysis, data mining, and data visualization. It only takes a minute to sign up.
Sign up to join this communitympg = mileage per gallon and hp = horsepower
Why is this model a linear model despite having a square of horsepower in it?
In order to explain this, I would consider the following quadratic function.
By comparing this function with your function, x1
would be similar to your hp
(horsepower).
Actually what we have really done is, we have created a new feature x2
where
By plugging this new feature to the above hypothesis we get the following function which is just like a linear model
Ok i got the answer. For the model to be linear it needs to be linear in terms of parameters not the predictors. Here betas are parameters and horsepower is predictor