Question: You are trying to t a multiple linear regression model for a given data set. You have already transformed your data by appending a column

 You are trying to t a multiple linear regression model for

You are trying to t a multiple linear regression model for a given data set. You have already transformed your data by appending a column of all one-3, which resulted in a nal data matrix: 1 3:1,; 3:112 I\": 1 322,1 32,2 2:2!\" X: 1 an 3311.2 was However, your model does not seem to be working well. It obtains poor loss in both training and test. (a) (b) A friend suggests that you should try mean centering your data columns. In other words, for each i, compute the column mean 5:; = %2}1=1 mm- and subtract 5:,- from every entry in column 16. Note that we won't mean center the rst column, as doing so would set the Is to (Is. Using Python broadcasting you might mean center by running: T = X[: ,l:] X[: ,1:] = T H np.mean(T, axis=0) Do you expect your friend's suggestion to improve the performance of the linear model. Will it help in all cases? Some cases? No cases? Another friend suggests normalizing your data columns to have unit standard deviation. In other words for each i, compute the column standard deviation 0,- = 3:22:1(593'; :T:t-)2 and divide every column by or. Using Python broadcasting you might run: '1' = X[: ,1:] X[: 11:] = Tp.std(T,axis=0) Do you expect your friends suggestion to improve the performance of the linear model. Will it help in all cases? Some cases? No cases? Would your answers to either of the two questions above change if you were tting the model with E2 regularization? In other words, instead of minimizing the squared loss L(,B) = \"y X\"; alone, you were minimizing LU?) + AME&quot

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Mathematics Questions!