title: Faster way to move data from a vector to a 2d array in python?
body: <p>This is my current code:</p>
  <pre><code>#move data from vector, A, into 2D array, H
      for i in range(0,nlat):
          jmin = nheader+1+i*nlon
          jmax = nheader+(i+1)*nlon
          A = A[jmin:jmax+1]
          H[i] = A
          A = np.array(Alist)
  </code></pre>
  <p>I have a very long vector, and I am taking certain data from it and putting it into a 2D array of dimension nlat x nlon. This setup works but it is very time consuming. Any suggestion of how to speed it up or rewrite it so it doesn't take as long would be very helpful.</p>