Hi, I find myself doing this:
In [244]: x Out[244]: array([[0, 1, 2], [3, 4, 5], [6, 7, 8]]) In [245]: y=x.copy() In [251]: y.dtype.char Out[251]: 'l' In [252]: dt=np.dtype([('a','l'),('b','l'),('c','l')]) In [254]: y.dtype=dt Is it okay? The problem is that it's not easy to rebuild the array. I tried with: y.astype(dt) np.array(y, dt) np.array(y.tolist(), dt) None worked. Bye. Ernest _______________________________________________ NumPy-Discussion mailing list NumPy-Discussion@scipy.org http://mail.scipy.org/mailman/listinfo/numpy-discussion