Printing output of evalfis to a static or edit textbox in GUIDE GUI
1 view (last 30 days)
Show older comments
I am trying to print the result of evalfis (fuzzy logic toolbox) to a textbox in a GUIDE gui.
For example, pushbutton10_callback when pressed prompts the user for inputs and then uses the inputs for the evalfis, then prints the results in a bar graph using bar.
I want to print Personal, Financial and Mailing to the text box.
% Print the evaluation outputs
% Obtain results of the personal output
Personal = evalfis(handles.a1, [personal1; personal2; personal3]);
% Obtain results of the financial evaluation.
Financial = evalfis(handles.a2, [financial1; financial2]);
% Obtain results of the mailing evaluation.
Mailing = evalfis(handles.a3, [Financial; Personal; social]);
X = categorical({'Personal', 'Financial', 'Mailing'});
X = reordercats(X, {'Personal', 'Financial', 'Mailing'});
Y = [Personal, Financial, Mailing];
b = bar(X, Y);
How do I do this?
5 Comments
Answers (1)
Walter Roberson
on 2 Aug 2020
handles.AppropriateHandle.String = num2str(Y);
This will give you problems if Y has multiple rows, unless handles.AppropriateHandle.Max > 1
See Also
Categories
Find more on Boundary Conditions in Help Center and File Exchange
Products
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!