how to find the position in a string array

 Réponse acceptée

Walter Roberson
Walter Roberson le 6 Avr 2014

2 votes

Read the documentation in ismember()

2 commentaires

thanks, I got it.
[a,b]=ismember(str,attributes)
b
I'd prefer this instead:
index = find(strcmp(attributes, str))

Connectez-vous pour commenter.

Plus de réponses (0)

Catégories

En savoir plus sur Get Started with MATLAB dans Centre d'aide et File Exchange

Tags

Community Treasure Hunt

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

Start Hunting!

Translated by