Open
Conversation
Aditya-k-23
suggested changes
May 29, 2025
There was a problem hiding this comment.
- In Question 3, should split the dataset as train (75%) and test (25%). Having a minority test set reduces the opportunity for the model to learn in the first place.
- Also should use
select_dtypes()anddrop()to select numeric predictors instead of manually choosing predictors based on their position to avoid errors.
Owner
Author
There was a problem hiding this comment.
I've implemented the fixes, thanks for tips!
Aditya-k-23
approved these changes
Jun 5, 2025
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What changes are you trying to make? (e.g. Adding or removing code, refactoring existing code, adding reports)
I've added the code to complete the assignment
What did you learn from the changes you have made?
I was able to practice doing a multivariable linear regression and evaluating it with RMSPE
Was there another approach you were thinking about making? If so, what approach(es) were you thinking of?
No
Were there any challenges? If so, what issue(s) did you face? How did you overcome it?
I had a hard time with creating the numeric_predictors variable, so I ended up using the method shown in assignment one for isolating the predictors into one variable that did not include the response variable or the non-numeric variables. I also had issues when it came time to use the test data, as I tried to make a new variable called numeric_predictors_test and use that the predict() method, but it gave me an error saying that I had to use the same features that were used in the fitting of the model. I ended up redefining the original numeric_predictors variable to use testing data, so I wouldn't have to use a different variable when predicting.
How were these changes tested?
Once completed, I saved and reran all the code blocks
A reference to a related issue in your repository (if applicable)
Checklist