How do I extract a substring in a cell array of strings?
13 visualizaciones (últimos 30 días)
Mostrar comentarios más antiguos
Abdullah Hamidi
el 4 de Mzo. de 2019
Comentada: Abdullah Hamidi
el 4 de Mzo. de 2019
I have loaded up a catalog of satellite and space debris entries on MATLAB and I am trying to extract everything that is debris.
As you can see in the attachment (column 4), I am trying to run a for loop to look for strings that contain the word 'deb' (and other corresponding fields) and save them separately. But I am just not getting anywhere. Any help would be hugely appreciated.
0 comentarios
Respuesta aceptada
KSSV
el 4 de Mzo. de 2019
[num,txt,raw] = xlsread(myfile) ;
C4 = txt(:,4) ;
idx = contains(C4,'DEB')
Note that for better help, you should attach your file not an image snippet.
5 comentarios
KSSV
el 4 de Mzo. de 2019
Ohhh....simple:
[num,txt,raw] = xlsread(myfile) ;
C4 = txt(:,4) ;
idx = contains(C4,'DEB')
iwant = txt(idx,:)
Más respuestas (0)
Ver también
Categorías
Más información sobre String en Help Center y File Exchange.
Productos
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!