Use Neural Network app to predict and calculate the MAPE error
7 visualizzazioni (ultimi 30 giorni)
Mostra commenti meno recenti
Hi guys, I'm new in Matlab I now I want to use Neural Network app to predict the data. I want to train all the value with 80% data and test with 20% data and use power as a target( don't minh about the cluster). I have read many document and answer but I think I did the wrong way. Thank you guyssss
0 Commenti
Risposte (1)
Omega
il 20 Nov 2024 alle 5:33
Hi Huy,
You can use the "Neural Network Fitting" application, which is well-suited for your tasks. The application allows you to specify the split ratios for training, validation, and testing. You can adjust these values according to your requirements.
To calculate the Mean Absolute Percentage Error (MAPE), you can export the predictions and actual values to the MATLAB workspace and use the following formula:
% Assuming y_true is the actual values and y_pred is the predicted values
y_true = ...; % Replace with actual values
y_pred = ...; % Replace with predicted values
% Calculate MAPE
mape = mean(abs((y_true - y_pred) ./ y_true)) * 100;
fprintf('Mean Absolute Percentage Error (MAPE): %.2f%%\n', mape);
For more information about MAPE, please refer to the following documentation link:
0 Commenti
Vedere anche
Categorie
Scopri di più su Sequence and Numeric Feature Data Workflows in Help Center e File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!