convert whole code to double

2 次查看(过去 30 天)
is it possible by anyway to convert whole code to double in a single step? For operations such as sparse single format and integer format doesnt work so double format has to be used
  2 个评论
Stephen23
Stephen23 2018-9-13
编辑:Stephen23 2018-9-13
"is it possible by anyway to convert whole code to double in a single step?"
No.
What class would expect the output of this to be?:
X = uint8(0)
KSSV
KSSV 2018-9-13
If your input is double then the output and calculations will be in double. Any ways we can help more on knowing the code.

请先登录,再进行评论。

采纳的回答

Walter Roberson
Walter Roberson 2018-9-13
No, it is not possible, as it would lead to errors because operations are not defined the same way on all of the data types. For example A([true, false]) is not the same as A([1,0])

更多回答(0 个)

类别

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

标签

Community Treasure Hunt

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

Start Hunting!

Translated by