convert string to cell

3 次查看(过去 30 天)
shaz
shaz 2012-11-15
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 个评论
Jan
Jan 2012-11-15
The question is not unique: Do you want to get {'a', 'b', 'c'} or {'a;', 'b;', 'c;'}?
Jan
Jan 2012-11-27
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.

请先登录,再进行评论。

采纳的回答

Azzi Abdelmalek
Azzi Abdelmalek 2012-11-15
编辑:Azzi Abdelmalek 2012-11-15
b=regexp(a,';','split')
b{:}

更多回答(0 个)

类别

Help CenterFile Exchange 中查找有关 Characters and Strings 的更多信息

Community Treasure Hunt

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

Start Hunting!

Translated by