Why are these two RMSE yield different results?

2 visualizaciones (últimos 30 días)
Raja Joko Musridho
Raja Joko Musridho el 8 de Abr. de 2018
Comentada: Raja Joko Musridho el 11 de Abr. de 2018
LM_error= sqrt(mean(((trueLm-estLm).^2),2));
LM_error= sqrt(sum(((trueLm-estLm).^2),2)/length(data));

Respuestas (1)

Image Analyst
Image Analyst el 8 de Abr. de 2018
Editada: Image Analyst el 8 de Abr. de 2018
Why should they be? The first method does not even use the array called data at all so it doesn't surprise me that they are different.
And why not simply use immse()?
  5 comentarios
Image Analyst
Image Analyst el 10 de Abr. de 2018
Not necessarily, but sum(x)/length(x) IS the same as mean(x)?
Raja Joko Musridho
Raja Joko Musridho el 11 de Abr. de 2018
Thank you
But I am still wondering why the results I got are different to each other. The sum((trueLM-estLM).^2)/length(x)

Iniciar sesión para comentar.

Categorías

Más información sobre Splines en Help Center y File Exchange.

Etiquetas

Productos

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by