Using cell array to define double

1 次查看(过去 30 天)
Luigi
Luigi 2024-5-24
评论: Stephen23 2024-5-24
Normally I create a 1x1 double as follows:
mydouble=1;
Now, say I create a cell array:
mycell = {'mydouble'}
I want to create the 1x1 double mydouble equal to 1 using the object mycell. How can I do that?

回答(1 个)

Torsten
Torsten 2024-5-24
移动:Torsten 2024-5-24
mydouble = 1;
mycell{1} = mydouble
mycell = 1x1 cell array
{[1]}

类别

Help CenterFile Exchange 中查找有关 Multidimensional Arrays 的更多信息

产品


版本

R2023b

Community Treasure Hunt

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

Start Hunting!

Translated by