Evaluate the GB regressor
Now that the test set predictions are available, you can use them to evaluate the test set Root Mean Squared Error (RMSE) of gb.
y_test and predictions y_pred are available in your workspace.
Questo esercizio fa parte del corso
Machine Learning with Tree-Based Models in Python
Istruzioni dell'esercizio
Import
mean_squared_errorfromsklearn.metricsasMSE.Compute the test set MSE and assign it to
mse_test.Compute the test set RMSE and assign it to
rmse_test.
Esercizio pratico interattivo
Prova a risolvere questo esercizio completando il codice di esempio.
# Import mean_squared_error as MSE
____
# Compute MSE
mse_test = ____
# Compute RMSE
rmse_test = ____
# Print RMSE
print('Test set RMSE of gb: {:.3f}'.format(rmse_test))