I was wondering what is the best way to convert an array of integers to a cell array of strings?
Thanks.

 採用された回答

Fangjun Jiang
Fangjun Jiang 2011 年 10 月 14 日

0 投票

a=magic(5)
b=mat2cell(a,ones(size(a,1),1),ones(size(a,2),1))
c=cellfun(@num2str,b,'uni',false)

その他の回答 (0 件)

カテゴリ

ヘルプ センター および File Exchange で Cell Arrays についてさらに検索

タグ

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by