I have a few functions that each returns 3 output values, within a for loop using i as a counter. Is there a nice way to assign values, in the sense that i am currently using:
for i=1:n [TestValues(i,1), assymp(1), names{1}] = ftesttype1(I(:,i),p,sign); [TestValues(i,2), assymp(2), names{2}] = ftesttype2(I(:,i),p,sign);...end
As you can see i have manually labelled them 1 and 2 for their places. Is there a way such taht the output will automatically move to the right spot ? – Ie. after ftesttype1 has returned its values ftesttype2 will put them in the right place without me needing to specify that spot 2 is to be used in the vectors TestValues, assymp and names.
The thing is i have meaby 50 such functions and how many changes sort of often. So i have to manually retype some 150 numbers alot (and check that i have done so correctly).
Thanks ALOT in advance!
Best Answer