Taking one figure out of a thousand figures

1 回表示 (過去 30 日間)
SNM Nima
SNM Nima 2022 年 12 月 11 日
コメント済み: SNM Nima 2022 年 12 月 11 日
I have a for loop in my code and this loop repeats a thousand times and each time gives a figure with a plot.
Is there a way to take one figure from the thousand drawn figures and put it back on another plot after the loop is finished?

採用された回答

KALYAN ACHARJYA
KALYAN ACHARJYA 2022 年 12 月 11 日
You can do that in multiple ways, easiest way
  1. Save the all data points in cell array { }
  2. Once the plots done and exited from for loop
  3. Plot any random cell elements from saved cell array.
for i=1...
plot_data{i}=
end
plot(plot_data{randi(length(plot_data))});
HTH
  1 件のコメント
SNM Nima
SNM Nima 2022 年 12 月 11 日
Thank you.

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

その他の回答 (0 件)

カテゴリ

Help Center および File ExchangeLine Plots についてさらに検索

Community Treasure Hunt

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

Start Hunting!

Translated by