MATLAB: Error: Unable to perform assignment because the left and right sides have a different number of elements.

error

I am unable to get this for loop working for some reason, I know it is in line 28 but not sure. Thanks for any help.

Best Answer

You are using a double for loop. I advise its best to use something like this
for ii=1:24
for jj=1:24
z(ii,jj)=normrnd(mu_SC(ii),std_SC(jj),1000);
end
end
Related Question