Cell array convert into double

1 次查看(过去 30 天)
Vishnu Dhakad
Vishnu Dhakad 2020-7-14
Hi,
I have below cell array of numeric values, I want to convert them into double array Input:
{[ 315]}
{[ 315]}
{[ 315]}
{[337.5000]}
{[337.5000]}
Please find the attached file

回答(1 个)

madhan ravi
madhan ravi 2020-7-14
Wanted = cat(1, cell_array{:})
  2 个评论
Vishnu Dhakad
Vishnu Dhakad 2020-7-14
Thanks for answer
I tried your code but I got error
Wanted = cat(1, WD01{:})
Error using cat
Dimensions of arrays being concatenated are not consistent.
madhan ravi
madhan ravi 2020-7-14
cell_array =
5×1 cell array
{[ 315]}
{[ 315]}
{[ 315]}
{[337.5000]}
{[337.5000]}
>> Wanted = cat(1, cell_array{:})
Wanted =
315.0000
315.0000
315.0000
337.5000
337.5000

请先登录,再进行评论。

类别

Help CenterFile Exchange 中查找有关 Data Type Conversion 的更多信息

产品


版本

R2019b

Community Treasure Hunt

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

Start Hunting!

Translated by