Change headers on the table result
2 次查看(过去 30 天)
显示 更早的评论
Hello,
So imagine if i have this calculation to make
A = [1,2,3,4,5,6,7,8,9,10];
B = zeros(1,10);
for j = 1:10
B = 1+A;
end
The end result is a matrix B like B = 2 3 4 5 6 7 8 9 10 11.
In the workspace I have a table B to open, it open "like" the tables from excel, I was wondering if I can change the header to let's say X1,X2,X3,...Xn, being n the number of columns of A.
Thanks for your time, Tiago
0 个评论
采纳的回答
Andrei Bobrov
2018-1-30
编辑:Andrei Bobrov
2018-1-30
B = 2:11;
out = array2table(B,'v',cellstr(string('X') + (1:numel(A))'))
5 个评论
更多回答(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!