MAPE Calculation | Regression Learner App
13 次查看(过去 30 天)
显示 更早的评论
I want to calculate the relative mean absolute error (or as a percentage ) the mean absolute percentage error of my regression models in a Regression Learner app session .
I could only find provision for RMSE, R^2 and MAE. How can I automatically calculate MAPE?
I am also trying to calculate myself. But when I export Error plot as a figure , I am unable to get the X and Y data of the opened figure.
I tried using the following code, but I get
s = 0x0 empty GraphicsPlaceholder array.
Unrecognized method, property, or field 'XData' for class 'matlab.graphics.GraphicsPlaceholder'
s=findobj(gca,'Type','Scatter');
X = s.XData;
Y = s.YData;
0 个评论
回答(1 个)
Drew
2024-1-31
Mean Absolute Percentage Error (MAPE) was added to the Regression Learner app in R2024a. As of this writing, you can access R2024a in the prerelease version. See https://www.mathworks.com/help/releases/R2024a/stats/release-notes.html and https://www.mathworks.com/help/releases/R2024a/stats/assess-model-performance-in-regression-learner.html#bvj4xvn-1 .
For the separate question of using handle graphics to access data in a figure that was exported from the Regression Learner plot, see https://www.mathworks.com/matlabcentral/answers/2072706-extract-predictor-and-reponse-as-an-array-format-from-ml-app
Also, note that the mape() function was added to the MATLAB command line in R2022b https://www.mathworks.com/help/matlab/ref/mape.html
If this answer helps you, please remember to accept the answer.
0 个评论
另请参阅
类别
在 Help Center 和 File Exchange 中查找有关 Gaussian Process Regression 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!