Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR PYTHON

Root Mean Squared Error

# Needed packages
from sklearn.metrics import mean_squared_error

#  Values to compare
y_true = [[0.5, 1],[-1, 1],[7, -6]]
y_pred = [[0, 2],[-1, 2],[8, -5]]

# Root mean squared error (by using: squared=False)

rmse = mean_squared_error(y_true, y_pred, squared=False)

print(rmse)
Source by scikit-learn.org #
 
PREVIOUS NEXT
Tagged: #Root #Mean #Squared #Error
ADD COMMENT
Topic
Name
3+3 =