필터 지우기
필터 지우기

Uitable very slow updating displayed data

조회 수: 3 (최근 30일)
claudio
claudio 2021년 6월 25일
답변: leila sa 2022년 6월 14일
Hi all
I create a small GUI where three uitable are implemented to display some data. Interactively data can be modified or completely changed. In this second situation the data change become very slow (~50 seconds for displaying 20x20 data, double type). To speed up the process I used the 'setValueAt()' method taking the control of the proper java handle related to the uitable. But without any improvement. What is the hidden bottle neck?
the following code show the callback used to set the data
function setDataToTable(dataTable)
% dataTable = struct with array of doubles
% table = handle of table
% profile on
fcn = table.DataChangedCallback;
table.DataChangedCallback = []; % disable for a while to avoid refresh for each value
kk = 0; jj = 0;
if isfield(dataTable,'newData')
for kk = 1:size(dataTable.newData,2)
for jj = 1:size(dataTable.newData.value,1)
table.setValueAt( ...
dataTable.newData(jj,kk),jj - 1,kk - 1);
end
end
end
table.DataChangedCallback = fcn; % restore callback
% profile off
% profile viewer
end
Thanks in advance for any comment or suggestion
claudio

답변 (1개)

leila sa
leila sa 2022년 6월 14일
Hi.
I have the same problem. I will be gratefull for any suggestion

카테고리

Help CenterFile Exchange에서 Migrate GUIDE Apps에 대해 자세히 알아보기

태그

제품


릴리스

R2017a

Community Treasure Hunt

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

Start Hunting!

Translated by