フィルターのクリア

How to plot while loop iteration in same figure

3 ビュー (過去 30 日間)
hotait hassane
hotait hassane 2021 年 4 月 3 日
コメント済み: Cris LaPierre 2021 年 4 月 3 日
MT= [m, n] matrix
%%%%%%%%%%%%%%%%%%%%%%%%%%%
while cidx == 1
i=i+4;
Z = MT (1: i, :);
[idx,cidx] = clusterer(Z);
plot(clusterer,Z,idx);
End
%%%%%
with cidx = 11111111111111111111111111111 2222
Knowing that the program gives me a new figure each time I do an iteration cidx=1 (10 figures for 10 iterations) so how I can plot the figures in the same one ?
Thanks in advance

回答 (1 件)

Cris LaPierre
Cris LaPierre 2021 年 4 月 3 日
Use hold on and hold off as appropriate. You can learn more about them in Ch 9 of MATLAB Onramp.
  2 件のコメント
hotait hassane
hotait hassane 2021 年 4 月 3 日
Thank you Cris LaPierre, i tired it but it doesn't work
Cris LaPierre
Cris LaPierre 2021 年 4 月 3 日
What did you try? It'll work if done correctly. Have you gone through ch 9 of the onramp yet?

サインインしてコメントする。

カテゴリ

Help Center および File ExchangeGraphics Object Programming についてさらに検索

Community Treasure Hunt

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

Start Hunting!

Translated by