powered by
Compute the Mean Squared Error between predicted and actual values.
pred.MSE(y_true, y_pred)
The mean squared error.
Actual values.
Predicted values.
y_true <- c(1, 2, 3, 4, 5) y_pred <- c(1.1, 2.2, 2.9, 4.1, 4.8) pred.MSE(y_true, y_pred)
Run the code above in your browser using DataLab