Unable to perform assignment because the indices on the left side are not compatible with the size of the right side.
1 回表示 (過去 30 日間)
古いコメントを表示
fid = fopen('zaki_susu_preproc.txt','r'); %open file txt
C = textscan(fid,'%f%f%f%f');
fclose(fid);
YR = cell2mat(C); %ERROR
x1 = YR(:,2:2); %choose one column
fs = 250; %sampling freq
figure(1) %plot sinyal
plot(x1)
Unable to perform assignment because the indices on the left side
are not compatible with the size of the right side.
Error in cell2mat (line 46)
M(i,j) = C{i,j};
Error in coba1 (line 4)
YR = cell2mat(C);
1 件のコメント
Image Analyst
2022 年 9 月 24 日
You forgot to attach 'zaki_susu_preproc.txt'! So what can we do?
If you have any more questions, then attach your data and code to read it in with the paperclip icon after you read this:
回答 (1 件)
Walter Roberson
2022 年 9 月 25 日
Error in cell2mat (line 46)
M(i,j) = C{i,j};
That line of code does not exist in Mathworks cell2mat, at least not in 2019 or later. What shows up for
which -all cell2mat
0 件のコメント
参考
カテゴリ
Help Center および File Exchange で Data Type Conversion についてさらに検索
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!