Direct link to this answer

If myClass was instead a System object (such as many filters and other signal processing algorithms found in MATLAB toolboxes), then you'd want to use cell arrays instead, via something like the following:

N = 1000;

obj = cell(N,1);

for i = 1:N

obj{i} = myClass;

end

In that case, I believe the syntax could get a bit more involved so I thought I'd include an example for reference: