MATLAB爱好者论坛-LabFans.com

MATLAB爱好者论坛-LabFans.com (https://www.labfans.com/bbs/index.php)
-   资料存档 (https://www.labfans.com/bbs/forumdisplay.php?f=72)
-   -   MATLAB-连接单元格数组中的项目 (https://www.labfans.com/bbs/showthread.php?t=23637)

poster 2019-12-10 20:42

MATLAB-连接单元格数组中的项目
 
我有一个单元格数组:

X = {1x2} {1x2} X{1} = '' A X{1 2} = 10 113 我希望以这种方式连接子细胞

Y = 10 113A 谢谢,S :-)



[B]回答:[/B]

y = cellfun(@(a, b) sprintf('%d%s', b, a), x{1}, x{2}, 'UniformOutput', false);

[url=https://stackoverflow.com/questions/3179854]更多&回答...[/url]


所有时间均为北京时间。现在的时间是 01:04

Powered by vBulletin
版权所有 ©2000 - 2025,Jelsoft Enterprises Ltd.