Evaluate the SGB regressor
You have prepared the ground to determine the test set RMSE of sgbr
which you shall evaluate in this exercise.
y_pred
and y_test
are available in your workspace.
This exercise is part of the course
Machine Learning with Tree-Based Models in Python
Exercise instructions
Import
mean_squared_error
asMSE
fromsklearn.metrics
.Compute test set MSE and assign the result to
mse_test
.Compute test set RMSE and assign the result to
rmse_test
.
Hands-on interactive exercise
Have a go at this exercise by completing this sample code.
# Import mean_squared_error as MSE
____
# Compute test set MSE
mse_test = ____
# Compute test set RMSE
rmse_test = ____
# Print rmse_test
print('Test set RMSE of sgbr: {:.3f}'.format(rmse_test))