How to find the row and column of elements where the value of A is the same as B
1 vue (au cours des 30 derniers jours)
Afficher commentaires plus anciens
Doug
le 15 Juil 2014
Commenté : Image Analyst
le 15 Juil 2014
A and B are matrices. Is there a function I'm missing?
0 commentaires
Réponse acceptée
Alfonso Nieto-Castanon
le 15 Juil 2014
[i,j] = find(A==B);
2 commentaires
Image Analyst
le 15 Juil 2014
Make sure A and B are integers or else see the FAQ: http://matlab.wikia.com/wiki/FAQ#Why_is_0.3_-_0.2_-_0.1_.28or_similar.29_not_equal_to_zero.3F
Plus de réponses (0)
Voir également
Catégories
En savoir plus sur Matrix Indexing 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!