"scatteredInterpolant" Function Does Not Accept Inputs of Type Single.
1 回表示 (過去 30 日間)
古いコメントを表示
MathWorks Support Team
2019 年 8 月 7 日
回答済み: MathWorks Support Team
2019 年 8 月 9 日
The function "scatteredInterpolant" does not accept inputs of type single. Is there any existing workaround?
The follow code block produces an error when passing variables of type single as input into the "scatteredInterpolant" function.
x = (1:10)';
y = randi([1,10], 10,1);
z = (11:20)';
F = scatteredInterpolant(single(y), single(x), single(z), 'linear', 'linear');
Error using scatteredInterpolant
The input points must be a double array.
採用された回答
MathWorks Support Team
2019 年 8 月 7 日
One workaround is to cast the variables of type single into type double.
0 件のコメント
その他の回答 (0 件)
参考
カテゴリ
Help Center および File Exchange で Logical についてさらに検索
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!