Get data from table to editfield
3 views (last 30 days)
i have created an app where i get the data from a table & display in GUI, i need to get the minimum value/ last value from the table into an editfield, table consists of three rows, i want minimum value data from second & third column, kindly support in this regard
[file,path] = uigetfile('*.xlsx');
app.t = readtable(fullfile(path,file));
app.UITable.Data = app.t;
app.t = app.UITable.Data;
app.t.Properties.VariableNames(1) = "Time";
app.t.Properties.VariableNames(2) = "Angle RH";
app.t.Properties.VariableNames(3) = "Angle LH";
app.UITable.ColumnName = app.t.Properties.VariableNames;
app.x = table2array(app.t(:,"Time"));
app.y = table2array(app.t(:,"Angle RH"));
app.y1 = table2array(app.t(:,"Angle LH"));
ResultData = plot(app.UIAxes3,app.x,app.y,app.x,app.y1);
app.RHRemainingAngleEditField.Value = AAA;
app.LHRemainingAngleEditField.Value = AAA;
RAGHUNATHRAJU DASHARATHA on 11 Nov 2022
As per my understanding you want to get minimum value from 2nd and 3rd column of your data.
I assume you have converted your table of data to array where app.y and app.y1 are second and third columns of your data.
To get minimum value from those columns you can use min function. To know more refer this documentation link.