How to calculate 'compare' funtion in Matlab
1 view (last 30 days)
Show older comments
I am studying RMSE and NRMSE according to ' https://en.wikipedia.org/wiki/Root-mean-square_deviation ' , ' https://www.mathworks.com/help/ident/ref/compare.html '
For example, I made like below.
Why is the NRMSE value different between NRMSE manually by wikipedia and NRMSE by compare code of MATLAB?
Could you teach me how to calculate 'compare' function mathmatically?
V1 = [11.5 7.6 6.7 8.3 7.7 7.4 6.5 5.6 6.6 11.2 11.9]; % obseved data
V2 = [11.9 10.8 8.3 9.6 11.4 10.2 12.4 9.6 8.3 8 9]; % estimationd data
RMSE = sqrt(mean((V1-V2).^2)); % RMSE = 3.14107
NRMSE = RMSE/(max(V2)-min(V2)) % NRMSE = 0.71
% to use compare
VV1 = iddata(V1', Vt');
VV2 = iddata(V2', Vt');
compare(VV1,VV2) % -48.46%
compare(VV1,VV2) % -116.8%
0 Comments
Answers (0)
See Also
Categories
Find more on Statistics and Machine Learning Toolbox in Help Center and File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!