How to remove rows in a cell array?
1 次查看(过去 30 天)
显示 更早的评论
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?
0 个评论
采纳的回答
Sulaymon Eshkabilov
2023-1-27
Here is how you can do it:
load('stations1.mat');
[Rs, Cs] = find(cellfun(@isempty, stations1));
stations1(Rs,:)=[];
0 个评论
更多回答(0 个)
另请参阅
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!