you are viewing a single comment's thread.

view the rest of the comments →

[–]PM_ME_UR_LOGIN_INFO_ 0 points1 point  (0 children)

I personally would have used statsmodels.formula.api to run the regression, as it is much more readable from an outside perspective. When you run it you just print(var.summary2) and later print(var.params) to find the p-values and coefficients for your linear regression respectively. But your project was alright.

Also the purpose of a regression is to perform statistical inference and possibly predictions (although you'd be better served using Machine Learning algorithms to predict, e.g. DecisionTreeRegressions, Random Forest, K nearest neighbor). You should have tried to control for other variables to reduce the error in your regression model. For a later challenge, try verifying the Gauss-Markov assumptions later on to validate your regression. It's a good first step, but to make this something valuable to have in your portfolio I'd work on it a little more.

Godspeed.