I can I duplicate raws of variables?
1 回表示 (過去 30 日間)
古いコメントを表示
I have imported an xls file spread sheet and I need to replicate six time each raw.
Ex. a1,b1,c1,d1 a2,b2,c2,d2 .................. ..................
Into a1,b1,c1,d1 a1,b1,c1,d1 a1,b1,c1,d1 a1,b1,c1,d1 a1,b1,c1,d1 a1,b1,c1,d1
a2,b2,c2,d2 a2,b2,c2,d2 a2,b2,c2,d2 a2,b2,c2,d2 a2,b2,c2,d2 .................. ..................
0 件のコメント
採用された回答
Youssef Khmou
2014 年 11 月 27 日
try this standard method
a=[1:3];
b=[];
for n=1:6
b=[b a];
end
2 件のコメント
Youssef Khmou
2014 年 11 月 28 日
hi Maria, you add a semicolon to the above code :
%....
b=[]
for n=1:6
b=[b;a];
end
その他の回答 (0 件)
参考
カテゴリ
Help Center および File Exchange で Data Import and Analysis についてさらに検索
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!