Question: PLEASE TYPE OUT RESPONCES FOR EACH STEP BT NUMBER. NO HANWRITTEN. * Step 5: Multiple regression model to predict miles per gallon using weight and
PLEASE TYPE OUT RESPONCES FOR EACH STEP BT NUMBER. NO HANWRITTEN.
*

Step 5: Multiple regression model to predict miles per gallon using weight and horsepower This block of code produces a multiple regression model with "miles per gallon" as the response variable, and "weight" and "horsepower" as predictor variables. The ols method in statsmodels.formula.api submodule returns all statistics for this multiple regression model. OLS Regression Results Dep. Variable: mpg R-squared: 0.834 Model : OLS Adj. R-squared: 0. 821 Method: Least Squares F-statistic: 67.71 Date: Mon, 05 Apr 2021 Prob (F-statistic) : 3. 02e-11 Time : 14:00 : 05 Log-Likelihood: -69.819 No. Observations: 30 AIC: 145. 6 Df Residuals: 27 BIC: 149.8 Df Model : 2 Covariance Type: nonrobust coef std err P> | t [0 . 025 0.975] Intercept 37. 6345 1 . 648 22. 840 0. 000 34 . 254 41 . 015 wt -3. 9548 0. 645 -6.129 0. 000 -5.279 -2. 631 hp -0. 0323 0. 009 -3.544 0 . 001 -0. 051 -0. 014 Omnibus : 4. 869 Durbin-Watson: 1. 702 Prob (Omnibus ) : 0. 088 Jarque-Bera (JB) : 3.667 Skew : 0 . 848 Prob (JB) : 0. 160 Kurtosis : 3. 241 Cond. No. 585. Warnings : [1] Standard Errors assume that the covariance matrix of the errors is correctly specified
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
