[Numpy-discussion] indexing recarrays

John [H2O] washakie@gmail....
Mon Jul 20 06:54:26 CDT 2009


I have a file containing mixed data types: strings, floats, datetime
output(i.e. strings), and ints. Something like:

#ID, name, date, value
1,sample,2008-07-10 12:34:20,344.56

Presuming I get them nicely into a recarray (see my other  
http://www.nabble.com/recarray-and-datetime-objects-td24568340.html post )
then I would like to work with them using the convention that I have become
used to:

D[:,0] #means D for all rows, column 0

But it seems now I have to use:

D['columnID']

Am I missing something, or is there a way to keep referencing columns by the
column integer index??

Thanks!


On another note... are recarrays and structured arrays the same??


-- 
View this message in context: http://www.nabble.com/indexing-recarrays-tp24568432p24568432.html
Sent from the Numpy-discussion mailing list archive at Nabble.com.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://mail.scipy.org/pipermail/numpy-discussion/attachments/20090720/a39ed223/attachment.html 


More information about the NumPy-Discussion mailing list