Error- Assignment has more non-singleton rhs dimensions than non-singleton subscripts?
古いコメントを表示
I'm trying to reshape data from a file(A), into a matrix(dcburn) that I made in a certain way using for loops. it keeps giving me this error. I tried doing it multiple ways this is one of them.
A = load('dc.burn.out.txt');
n = length(A);
dcburn = ones(214,223)*-99999;
numrow = 214;
numcol = 223;
k = 1:1:n;
for i = numrow:-1:1;
for j = 1:1:numcol;
dcburn(i,j) = A(k);
end
end
6 件のコメント
Birdman
2018 年 4 月 9 日
Can you share your data?
KSSV
2018 年 4 月 9 日
Check the size A(k)...it could be a vector and you are trying to save it into a single location
Birdman
2018 年 4 月 9 日
Your code is already shared. Your txt file is needed.
Alexis Diaz
2018 年 4 月 9 日
Birdman
2018 年 4 月 9 日
Find Attach file icon, next to the Help button.
Alexis Diaz
2018 年 4 月 9 日
編集済み: Alexis Diaz
2018 年 4 月 9 日
採用された回答
その他の回答 (0 件)
カテゴリ
ヘルプ センター および File Exchange で Logical についてさらに検索
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!