How to remove rows in a cell array?

1 回表示 (過去 30 日間)
Behrooz Daneshian
Behrooz Daneshian 2023 年 1 月 27 日
回答済み: Sulaymon Eshkabilov 2023 年 1 月 27 日
Hi all,
I have a cell array called "stations1". I want to remove any row for which column 9 is empty ([]). Can anyone one help me with that?

採用された回答

Sulaymon Eshkabilov
Sulaymon Eshkabilov 2023 年 1 月 27 日
Here is how you can do it:
load('stations1.mat');
[Rs, Cs] = find(cellfun(@isempty, stations1));
stations1(Rs,:)=[];

その他の回答 (0 件)

カテゴリ

Help Center および File ExchangeData Types についてさらに検索

Community Treasure Hunt

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

Start Hunting!

Translated by