Re: [Numpy-discussion] Less dimensions than expected with record array

2011-05-02 Thread Christopher Barker
ndarray has 2 dimensions but record array has 1 dimensions This makes seemingly reasonable things, like using apply_along_axis() over a table of data with named columns, impossible: each row (record) is treated as one array element, so the structured array is only 1d. If you have

[Numpy-discussion] Less dimensions than expected with record array

2011-04-29 Thread Alan Gibson
Hello all, This question may seem elementary (mostly because it is), but I can't find documentation anywhere as to why the following are true: import numpy as np data = [(1,2,3),(4,5,6),(7,8,9)] dt = [('a',int),('b',int),('c',int)] normal_array = np.array(data) record_array = np.array(data,

Re: [Numpy-discussion] Less dimensions than expected with record array

2011-04-29 Thread josef . pktd
On Fri, Apr 29, 2011 at 10:56 PM, Alan Gibson dyssid...@gmail.com wrote: Hello all, This question may seem elementary (mostly because it is), but I can't find documentation anywhere as to why the following are true: import numpy as np data = [(1,2,3),(4,5,6),(7,8,9)] dt =