compare model result using neural network
2 Ansichten (letzte 30 Tage)
Ältere Kommentare anzeigen
hi,
For predicting a parameter I have two different equations. I also have my own observations and want to compare them with prediction results to see wich equation is better. I wanted to use neural network like grnn to do this job.
If you have any information in this regard and how to do it, I would be grateful for your help.
0 Kommentare
Antworten (1)
Ayush Aniket
am 12 Jun. 2025
One way to do this would be by using a Generalized Regression Neural Network (GRNN). GRNN is particularly useful for function approximation and regression tasks, making it well-suited for your problem. Refer the code snippet below for the general steps that you can follow:
% Load dataset (assuming data to be the variable that stores your data)
X = data.inputs; % Independent variables
Y_actual = data.observed_values; % Actual observations
% Train GRNN model
sigma = 0.1; % Smoothing parameter (adjust as needed)
grnnModel = newgrnn(X', Y_actual', sigma);
% Generate predictions using equations
Y_pred_eq1 = equation1(X); % Replace with actual equation
Y_pred_eq2 = equation2(X); % Replace with actual equation
% Compute GRNN predictions
Y_pred_grnn = sim(grnnModel, X');
% Compare errors
mse_eq1 = mean((Y_pred_eq1 - Y_pred_grnn).^2);
mse_eq2 = mean((Y_pred_eq2 - Y_pred_grnn).^2);
% Determine best equation using errors
Refer the following documentation to read more about the function: https://www.mathworks.com/help/deeplearning/ref/newgrnn.html
0 Kommentare
Siehe auch
Kategorien
Mehr zu Define Shallow Neural Network Architectures finden Sie in Help Center und File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!