Creating a new string matrix
17 次查看(过去 30 天)
显示 更早的评论
Can ['abc';'ef';'xyz'] be used to create a new string matrix
1 个评论
采纳的回答
更多回答(1 个)
Bruno Luong
2018-10-15
编辑:Bruno Luong
2018-10-15
I will pad appropriate number of ascii-0 characters to the tail of the shorter strings to make them a matrix.
>> char({'abc';'ef';'xyz'})
ans =
3×3 char array
'abc'
'ef '
'xyz'
>>
0 个评论
另请参阅
类别
在 Help Center 和 File Exchange 中查找有关 Characters and Strings 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!