matlab:cellstr

S = ['abc', 'defg'; 'hi']

S = 

       abc

       defg

        hi

 

whos S
  Name      Size         Bytes  Class
  S         3x4             24  char arrayThe following command returns a 3-by-1 cell array.c =
 
cellstr(S)
 
c = 
    'abc' 
    'defg'
    'hi'
 
whos c
  Name      Size         Bytes  Class
  c         3x1            198  cell array
posted @ 2013-08-05 22:20  BeatHeart  阅读(1193)  评论(0编辑  收藏  举报