MATLAB Answers

0

How to calculate RMSE from Simulink Scope plots

Hello All,
I have a plot containing a simulated as well as an experimental data of a system in simulink . I want to calculate the Root mean square error (RMSE) of the data. Can anyone explain to me how to extract data from the scope and calculate the RMSE ?

  0 Comments

Sign in to comment.

1 Answer

Answer by Shivam Sardana on 30 May 2019
 Accepted Answer

To log the data from Scope block, check Save Simulation Data Using a Scope Block in Common Scope Block Tasks. To calculate RMSE (Root Mean Square Error),
RMSE = sqrt(mean((simulatedData - experimentalData).^2));

  1 Comment

Sign in to comment.