Cool - Now that would be some seriously dense, efficient code! Will have to play with numpy sometime.


R.


On 17-Sep-09, at 12:25 PM, Chris Colbert wrote:

if you have numpy installed:


ln[12]: import numpy as np
In [13]: k = np.array([('a', 'bob', 'c'), ('p', 'joe', 'd'), ('x',
'mary', 'z')])

In [14]: k
Out[14]:
array([['a', 'bob', 'c'],
       ['p', 'joe', 'd'],
       ['x', 'mary', 'z']],
      dtype='|S4')

In [15]: k[:,1]
Out[15]:
array(['bob', 'joe', 'mary'],
      dtype='|S4')

--
http://mail.python.org/mailman/listinfo/python-list

Reply via email to