It tells us the average loss/distance between our predicted values and target in the dataset
It's simply how much the trained model disagrees with the actual Target value
and It tells us how large the errors that our model makes are.
RMSE is computed with the formula below in pic:
Here,
✔ ' Predicted' is the Value predicted by the Model
✔ 'Actual" is the Target value(y)
✔ 'N' is the number of observations in the dataset
Let us break the formula down :
Here we take the difference between the Predicted Value and the Actual target, This is the 'ERROR', and square them
We take the sum of these squared differences, where the Sum goes from 1 to 'N' and N is the sample size of the dataset
Then Average is calculated for the Sum of these squared differences and is known as the Mean squared Error
The square root of the Mean squared Error is determined to obtain our Metric
Root Mean Squared Error (RMSE)
The Implementation of RMSE in Code :
We can use Numpy while implementing RMSE to make code more clear and Fast
Below is the code 👇
Conclusion :
◾ RMSE is calculated to identify how well the model fits with the data
◾ Lesser the RMSE value higher the Accuracy is
◾ Also to note that, If the model gives low RMSE on training data and high RMSE on testing data,Then its an overfitting model
And That's a wrap!
If you enjoyed this thread:
1. Follow me @Santhoscheeku77 for more on Python and ML contents 2. RT the tweet below to share this thread with your audience