How can i delete cell from cell array?

3 vues (au cours des 30 derniers jours)
Mira le
Mira le le 15 Déc 2019
Commenté : Image Analyst le 15 Déc 2019
I have two cell array,
W =
1×2 cell array
[1×2 double] [1×2 double]
F =
3×2 cell array
[1×2 double] []
[1×2 double] [1×2 double]
[1×2 double] []
I want to check if cell value in F contains in W, then I will delete the cell value in W
please help me.
  4 commentaires
Adam Danz
Adam Danz le 15 Déc 2019
Modifié(e) : Adam Danz le 15 Déc 2019
So if F{n} equals [4,8] and W{m} equals [5,8] you want to remove the 8 in W{m}, is the correct? The final result would be W{m}=[5]. (That's what a complete example would look like).
Image Analyst
Image Analyst le 15 Déc 2019
You might try ismember() with the rows option. Or try a loop comparing W with each row of F with isequal(). Please attach the actual F and W in a .mat file with the paper clip icon.

Connectez-vous pour commenter.

Réponses (0)

Catégories

En savoir plus sur Logical dans Help Center et File Exchange

Produits


Version

R2017a

Community Treasure Hunt

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

Start Hunting!

Translated by