MATLAB: Creating an array of probability distribution objects

array of objectspdfprobability distribution objects

I would like to create an array of different distribution fits to use them later. I am not sure how to do something like this:
for i=1:10
pdArray(i)=fitdist(errs, 'tlocationscale');
end

Best Answer

You could use a cell array:
for i=1:10
pdArray{i}=fitdist(errs, 'tlocationscale');
end