Page 1 of 1

use NumPy:

Posted: Mon May 02, 2022 12:01 pm
by answerhappygod
use NumPy:
Use Numpy 1
Use Numpy 1 (59.49 KiB) Viewed 32 times
7. Feature Egineering Adding/removing and processing features in the feature set to try to improve the accuracy of the prediction a. Choose and add new features to the X feature set and store it in a new variable X1 b. Divide the data into x1_test, X1_train, y1_test, y1_train as before. The train data set should contain 300 datapoints and the test dataset should contain 100 as before. c. Perform linear regression on the new X1_train to find corresponding B1 (betal) d. Use B, to predict Chance of Admit for data in X1_test e. Calculate and print the RMSE error for the prediction. f. Go back to step a to try new different feature sets to lower the RMSE error as much as you can Note: You can use np.column_stack() to stack new features to the previous processed feature set.