フィルターのクリア

Plot specific cells of cell array

5 ビュー (過去 30 日間)
george korris
george korris 2022 年 9 月 14 日
コメント済み: george korris 2022 年 9 月 14 日
Hi everyone i have a cell array that has some empty cells end the other ones are filled with 1x30 double numbers.
Does anyone know how can i plot only the filled cells vs lets say the numbers 1 to 30 and save each separate plot?
My cell array looks like this but with more cells
[] []
1x30 double 1x30 double
[] []
1x30 double 1x30 double

採用された回答

Chunru
Chunru 2022 年 9 月 14 日
A{1,1}=[]; A{1,2}=[];
A{2,1}=rand(1, 30); A{2,2}=rand(1,30);
A{3,1}=[]; A{3,2}=[];
for i=1:numel(A)
if ~isempty(A{i})
figure
plot(A{i})
% save figure
end
end
  1 件のコメント
george korris
george korris 2022 年 9 月 14 日
Thanks!!!

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

その他の回答 (0 件)

カテゴリ

Help Center および File Exchange2-D and 3-D Plots についてさらに検索

Community Treasure Hunt

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

Start Hunting!

Translated by