Borrar filtros
Borrar filtros

How do you use strsplit

4 visualizaciones (últimos 30 días)
Amanda
Amanda el 2 de Nov. de 2022
Respondida: Image Analyst el 2 de Nov. de 2022
I need to use strsplit to transform txt data into a cell array but i dont know how to do this
  2 comentarios
Matt J
Matt J el 2 de Nov. de 2022
What about the examples in the strsplit documentation?
KSSV
KSSV el 2 de Nov. de 2022
Show us your text.

Iniciar sesión para comentar.

Respuestas (1)

Image Analyst
Image Analyst el 2 de Nov. de 2022
For example
s = 'I need to use strsplit to transform txt data into a cell array but i dont know how to do this';
words = strsplit(s, ' ')
words = 1×21 cell array
{'I'} {'need'} {'to'} {'use'} {'strsplit'} {'to'} {'transform'} {'txt'} {'data'} {'into'} {'a'} {'cell'} {'array'} {'but'} {'i'} {'dont'} {'know'} {'how'} {'to'} {'do'} {'this'}

Categorías

Más información sobre MATLAB en Help Center y File Exchange.

Etiquetas

Community Treasure Hunt

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

Start Hunting!

Translated by