Code for calculating root mean squared error for data

This is a simple code which accurately calculates RMS error for real or complex data.

You are now following this Submission

er = rms_error(A1,A2)

here A1, A2 are original and reconstructed data. The order of A1,A2 doesn't matter, interchanging them will also give same result.

Cite As

Kamlesh Pawar (2026). Code for calculating root mean squared error for data (https://www.mathworks.com/matlabcentral/fileexchange/33595-code-for-calculating-root-mean-squared-error-for-data), MATLAB Central File Exchange. Retrieved .

Categories

Find more on Statistics and Machine Learning Toolbox in Help Center and MATLAB Answers

General Information

MATLAB Release Compatibility

  • Compatible with any release

Platform Compatibility

  • Windows
  • macOS
  • Linux
Version Published Release Notes Action
1.4.0.0

modified to display proper message while matrix dimension mismatch.

1.3.0.0

No update in the code, only changed the description of code

1.2.0.0

for loops were eliminated for fast implementation.

1.0.0.0