How to create an array with the same letter but different number
古いコメントを表示
Hi,
How can I create an array or cell, something like Variable = {'X1','X2','X3',...,'X43'}? when i give for example the length = 43.
So when I do my plots, i call put the title as title (variable(i))
Thanks!
1 件のコメント
Adam
2018 年 10 月 17 日
Variable = arrayfun( @(x) ['X', num2str( x )], 1:43, 'UniformOutput', false )
would create them all upfront.
採用された回答
その他の回答 (1 件)
カテゴリ
ヘルプ センター および File Exchange で Data Type Conversion についてさらに検索
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!