- Drag and drop the button onto the designer workspace
- Right click the button, hover over 'callbacks', select 'AddButtonPushedFcn callback'
- Paste the following code inside the ButtonPushed function
How can I apply Fuzzy Inference System in MATLAB App Designer
3 visualizaciones (últimos 30 días)
Mostrar comentarios más antiguos
Li Mun Ng
el 31 de Jul. de 2019
Comentada: Imam Pratama Setiady
el 3 de Feb. de 2021
Good day to all.
I have designed a system using Fuzzy Logic Toolbox and now I want to implement the Fuzzy Inference System in the standalone application which I am going to develop using MATLAB App Designer.
The basic function of the application is to calculate the risk level of the disease using fuzzy logic. The user will be required to insert the inputs in numerical forms and the ouput will be the risk level. So there will be a button to allow the user to press in order to generate the output.
My question is how to link the .fis file in the button of the App Designer?
0 comentarios
Respuesta aceptada
Subhadeep Koley
el 5 de Ag. de 2019
[file,path] = uigetfile('*.fis');
selectedfile = fullfile(path,file);
fuzzyLogicDesigner(selectedfile);
4. Save & Run the App.
0 comentarios
Más respuestas (3)
Li Mun Ng
el 6 de Ag. de 2019
4 comentarios
Subhadeep Koley
el 6 de Ag. de 2019
When I am executing the same code for the MATLAB in-built "tipper.fis" fis file it is giving me correct Output everytime.
function FuzzyButtonPushed(app, event)
fis = readfis('tipper');
i1=app.IP1EditField.Value;
i2=app.IP2EditField.Value;
inputs=[i1 i2];
output = evalfis(inputs,fis);
app.OPEditField.Value=output;
end
Therefore it is difficult to say which part went wrong without knowing what inputs your fis expect.
![Capture.PNG](https://www.mathworks.com/matlabcentral/answers/uploaded_files/232937/Capture.png)
chiwapon nitnara
el 2 de Mzo. de 2020
from this code i'm try to use this code to 2 output how to??? Thank you
1 comentario
Ver también
Categorías
Más información sobre Fuzzy Inference System Modeling en Help Center y File Exchange.
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!