Closed vd2309 closed 8 years ago
Hi @vd2309
I'm not sure why this might be happening. You can use the debugger to stop at this line in determine_search_location
and see if they dimensions indeed agree. However, it appears to me that you are using an older version of the code. Perhaps you might want to consider updating if you cannot resolve this. Let me know if it works.
Thanks, I no longer receive this error!
Hello!
My input data is 249 by 279 pixels and I tried K as 30, 40, and 100. Each time I run it I get the following error: Error using * Inner matrix dimensions must agree.
Error in determine_search_location (line 52) cm(:,1) = Coor.x'*A(:,1:nr)./sum(A(:,1:nr));
Error in update_spatial_components (line 43) IND = determine_searchlocation(A(:,1:K), method, options);
Although when I execute Coor.x'*A(:,1:nr)./sum(A(:,1:nr)); independently of the program, it gives me the correct result where t(Coor.x) is a 1 by 69471 matrix and A(:,1:nr) is a 69471 by 100 matrix, and the product yields a 1 by 100 vector.
So I do not know why it is giving me this error when I run the program.
Thank you very much! Virginia