Check if matrix has two identical rows
32 vues (au cours des 30 derniers jours)
Afficher commentaires plus anciens
Hi everyone, I wanted to check if a matrix has two identical rows. But i cant create a code that can do that. I was wondering if anyone has any idea on how to do that?
0 commentaires
Réponse acceptée
Dr. Seis
le 4 Jan 2012
If you want to remove identical rows, then
B = unique(A,'rows');
As a check, if size(B) ~= size(A), then you have at least two identical rows.
0 commentaires
Plus de réponses (1)
Voir également
Catégories
En savoir plus sur Resizing and Reshaping Matrices dans Help Center et File Exchange
Produits
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!