title: How to number matrices (histograms of images) with different sizes and retrieve them (Matlab)
body: <p>Using Matlab, I have 1000 color images, their histograms have the size either 384*256*3 or 256*384*3, so they are matrices.
  I want to number them, and later retrieve them. I know I cannot do this:</p>
  
  <pre><code>for z=1:1000
  H(:,:,:,z)={imread(strcat('image.orig/',int2str(z-1),'.jpg'))};
  end
  </code></pre>
  
  <p>But my question is how can I number the 1000 matrices and later I can get any of them, like for the first image, simply using</p>
  
  <pre><code>H(:,:,:,1)
  </code></pre>
  
  <p>to get the matrix. I know their sizes are different so I cannot set </p>
  
  <pre><code>H=zeros(384,256,3,1000);
  </code></pre>
  
  <p>because that only work for the matrices of the size 384*256*3.</p>
  
  <p>So what I should do to save the matrices and simply using a number from 1 to 1000 within a variable name to get any of the matrix?</p>
  
  <p>It is just how can I number different matrices and get each of them later?</p>
  
  <p>Hope I stated clear what's my problem. Thanks in advance!!</p>