Clear Filters
Clear Filters

Build An App for a trained ANN model for future predictions on new data

3 views (last 30 days)
Hi everyone,
New to Matlab app designer. I have trained an ANN model in Matlab. I want to develop a simple app (for possible deployment) using Matlab app designer. The app will have the following features
  1. 'Load data' button to load data
  2. Button that says 'Predict'. The loaded data will be predicted on the ANN model I have already trained
  3. a 'Result' interface that will display the predicted value with a unit in mL
  4. An 'Export' button that can export or save the result to an excel file.
I am not sure how to go about building an app with the features I have listed above and the codes that comes with it. Any example code or work will be truly appreciated!
Thanks!

Accepted Answer

Dinesh
Dinesh on 8 May 2023
Edited: Dinesh on 8 May 2023
Hello there,
To create an app in MATLAB App Designer with the features you want, you can follow these steps.
First, type "appdesigner" in the MATLAB command window to open App designer and then create a blank new app.
Then, in the App designer's design interface, you can easily add the components that you want by dragging them from the menu.
In your case, you can add
  • Three "Button" components ("Load data", "Predict" and "Export")
  • A "TextArea" componenet to display the predicted value with the unit.
You can arrange the components as desired by clicking on them and dragging in the "Design" tab.
You can then add callbacks for each button to perform the desired actions.
For the "Load data" button, the callback function might look something like this:
function LoadDataButtonPushed(app, event)
% Select and load data
[file, path] = uigetfile('*.mat', 'Select the data file');
if ~isequal(file, 0)
app.data = load(fullfile(path, file));
end
end
These steps shown above will help you get started with building your app.
The following is a link to a video that can help you understand the interface and build a basic app using App Designer:

More Answers (0)

Categories

Find more on Sequence and Numeric Feature Data Workflows in Help Center and File Exchange

Products


Release

R2022b

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!