how to solve this error "Subscripted assignment dimension mismatch."
1 次查看(过去 30 天)
显示 更早的评论
I tried looping through 231 samples of data but the error below occurs,
Subscripted assignment dimension mismatch.
Error in tvf_emd (line 132)
imf(nimf,:)=y(ind_remov_pad);
if flag_stopiter
for row_number = 1 : size(imf,1);
end
imf(nimf,:)=y(ind_remov_pad);
temp_x=temp_x - y(ind_remov_pad);
break;
each Imf is supposed to be 50x 500 but due to the 231 data samples , the imf matrix multiplies to become 50 x 115500.
This causes the above error even though I tried looping through each sample.
Please I will be grateful for any help.
9 个评论
Guillaume
2019-10-15
tvf_emd is a function, therefore you must be calling it from some other code (the same code that actually imports your data), maybe it's a script. The loop is in that other code. The function itself should be unmodified, e.g.
%script or function, NOT tvf_emd.m
matcontent = load('Total matrix data..mat')
DS_DATA_ODD = matcontent.DS_DATA_ODD;
out = zeros(50, size(DS_DATA_ODD, 2), size(DS_DATA_ODD, 1))
for row = 1:size(DS_DATA_ODD, 1)
out(:, :, row) = tvf_emd(DS_DATA_ODD(row, :));
end
回答(0 个)
另请参阅
类别
在 Help Center 和 File Exchange 中查找有关 Polynomials 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!