Filter löschen
Filter löschen

convert string to cell

2 Ansichten (letzte 30 Tage)
shaz
shaz am 15 Nov. 2012
i have a cell like
a = {'a;b;c;d;e;f;g;h'} % size is 1*1
how to place elements in to individual cell of a
output size = 1*8
  2 Kommentare
Jan
Jan am 15 Nov. 2012
The question is not unique: Do you want to get {'a', 'b', 'c'} or {'a;', 'b;', 'c;'}?
Jan
Jan am 27 Nov. 2012
It would be friendly to answer questions for clarifications. Otherwise it seems, like you are not interested in your own answers. This will reduce the motivation of others to answer your questions.

Melden Sie sich an, um zu kommentieren.

Akzeptierte Antwort

Azzi Abdelmalek
Azzi Abdelmalek am 15 Nov. 2012
Bearbeitet: Azzi Abdelmalek am 15 Nov. 2012
b=regexp(a,';','split')
b{:}

Weitere Antworten (0)

Kategorien

Mehr zu MATLAB finden Sie in Help Center und File Exchange

Community Treasure Hunt

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

Start Hunting!

Translated by