Effacer les filtres
Effacer les filtres

Find cell containing part of a string.

24 vues (au cours des 30 derniers jours)
sia ben
sia ben le 30 Juil 2018
I have a cell "A" of strings like {'A0_V2'; 'A0_V1'; 'B2_V4';...}. I want to find which numbers of A contains 'A0'. The answer can be ans = (1, 2).

Réponse acceptée

Image Analyst
Image Analyst le 30 Juil 2018
Try contains():
A = {'A0_V2'; 'A0_V1'; 'B2_V4'}
rowsWithString = contains(A, 'A0')

Plus de réponses (0)

Catégories

En savoir plus sur Multidimensional Arrays dans Help Center et File Exchange

Tags

Produits


Version

R2018a

Community Treasure Hunt

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

Start Hunting!

Translated by