Can I combine letters with numbers in the same matrix?
16 次查看(过去 30 天)
显示 更早的评论
Can I combine letters with numbers in the same matrix?
I have vector B return two letters for example [L M]
And another vector O returns two numbers for example [1 2]
Can I combine them to be like this?
[L M
1 2]
0 个评论
采纳的回答
Rik
2022-8-23
You have these options:
{'L','M';1,2}
["L","M";"1","2"]
['L','M';1,2]
double(['L','M';1,2])
1 个评论
Steven Lord
2022-8-23
Another option:
T = table(['L'; 'M'], [1; 2])
T(1, :)
更多回答(0 个)
另请参阅
类别
在 Help Center 和 File Exchange 中查找有关 Logical 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!