格式化字符数组 [英] formatting character arrays
问题描述
这是一个基本问题,但我找不到:
This is an elementary question, but I cannot find it:
我有一个3000x25的字符数组:
I have a 3000x25 character array:
2000-01-01T00:01:01 + 00:00
2000-01 -01T00:01:02 + 00:00
2000-01-01T00:01:03 + 00:00
2000-01-01T00:01:04 + 00:00
这些显然是时代。我想重新格式化数组为3000x1数组。如何将每行重新定义为数组中的一个条目?
These are obviously times. I want to reformat the array to be a 3000x1 array. How can I redefine each row to be one entry in an array?
(再次,这很简单,我很抱歉)
(Again, this is simple, I'm sorry)
推荐答案
p>除了转换为其他已显示的序列号之外,我想您只想转换为单元格数组的字符串:
Other than converting to serial date numbers as other have shown, I think you simply wanted to convert to cell array of strings:
A = cellstr(c)
其中 c
是3000x25的字符矩阵。
where c
is the 3000x25 matrix of characters.
这篇关于格式化字符数组的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!