any faster/straightforward way to find the location of empty cell in a cell array
1 vue (au cours des 30 derniers jours)
Afficher commentaires plus anciens
Hi:
I have a cell array called 'tmp', it is either '1' or 'empty' inside. I want to find the location where '1' is in the 'tmp', what I did is use 'for-loop' to read inside one-by-one. is there any more straightforward way to do this?
Thanks!
Yu
0 commentaires
Réponse acceptée
madhan ravi
le 26 Nov 2018
Modifié(e) : madhan ravi
le 26 Nov 2018
index=find(cellfun(@isempty,tmp(:))) %returns index
command window:
index =
1
2
3
4
10
11
>>
4 commentaires
Plus de réponses (0)
Voir également
Catégories
En savoir plus sur Data Types dans Help Center et File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!