How to save different matrices in a loop and then using them in another loop of the same program?
Info
This question is closed. Reopen it to edit or answer.
Show older comments
I have to save around 30 different matrices in one loop as A(1), A(2), A(3)....etc, which will be used in another loop for further calculations. Can someone please suggest me some solution with a simple example?
Answers (1)
Andrei Bobrov
on 16 Aug 2013
A = cell(30,1);
for jj = 1:30 % create your matrices
A{jj} = randi(20,randi(5),randi([2 5])); %
end
1 Comment
Tarun Gera
on 16 Aug 2013
This question is closed.
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!