How to display running FOR loop iterations (counts) on GUI window automatically
1 回表示 (過去 30 日間)
古いコメントを表示
Keshav Dev Singh
2014 年 3 月 11 日
コメント済み: Keshav Dev Singh
2014 年 3 月 18 日
Hell All,
I want to make a display button in my matlab GUI who can automatically show the running FOR loop iterations/ counts just like it shows in matlab workspace during programming running. e.g. 1,2,3...........200,....400....1000.....n-iterations
How to make such type of GUI DISPLAY window and what could be the script of this DISPLAY callback function?
Thank you very much in advance!
-- K.D.Singh
0 件のコメント
採用された回答
Dishant Arora
2014 年 3 月 11 日
h = figure;
set(h , 'Units' , 'Normalized' , 'position' , [0.4 0.4 0.2 0.2]);
h1 = uicontrol(h , 'style' , 'text' , 'Units' , 'Normalized'...
, 'position' , [0.4 0.4 0.2 0.2] , 'string' , 'Output');
for ii = 1:10
set(h1 , 'string' , num2str(ii));
pause(0.5)
drawnow;
end
7 件のコメント
Image Analyst
2014 年 3 月 12 日
The key thing was the drawnow. Anytime your display doesn't update fast enough, insert a drawnow. Here's another link to help you learn MATLAB: http://www.mathworks.com/matlabcentral/answers/8026-best-way-s-to-master-matlab
And for image processing demos (though only a handful of over a hundred that I have), you can go here: http://www.mathworks.com/matlabcentral/fileexchange/?term=authorid%3A31862
その他の回答 (0 件)
参考
カテゴリ
Help Center および File Exchange で Logical についてさらに検索
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!