Question: I have this error and couldnt fix it. and this is the error message, if anyone can help ! Thank you ! Compare the performance
I have this error and couldnt fix it.


and this is the error message, if anyone can help !

Thank you !
Compare the performance of the following models: Linear Regression, Lasso, Ridge, RandomForest. The metrics you will use to compare them are RMSE, MAE, and R-Squared. Your goal is to find a model that gives you the best performance. Fitting and evaluating the models 147 148 ValueError: Input X contains NaN. LinearRegression does not accept missing values encoded as NaN natively. For supervised learning, you might want to consider sklearn. ensemble. HistGradientBoostingClassifier and Regressor which accept missing values encoded as NaNs natively. Alternatively, it is possible to preprocess the data, for instance by using an imputer transformer in a p ipeline or drop samples with missing values. See https://scikit-learn.org/stable/modules/impute.html You can find a list of all estimators that handle NaN values at the following page: https://scikit-learn.org/stable/modules/imput e.html\#estimators-that-handle-nan-values
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
