A Saturday 01 December 2007, David Worrall escrigué:
> Hello,
>
> Forgive me if this is a simple question... I can't find the answer in
> the help files.
>
> given a table over which one is iterating, how does one 'cast' a
> table row into say a tuple.
>
>  >>> for row in tab.iterrows():
>
>       if row['time'] < 1: print type(row)
>
> returns
> <type 'tableExtension.Row'>

Well, the solution for this is a bit buried in the reference manual:

http://www.pytables.org/docs/manual/ch04.html#RowClassDescr

section "Special Methods".  In brief, row[:] will do the job for you.

Cheers,

-- 
>0,0<   Francesc Altet     http://www.carabos.com/
V   V   Cárabos Coop. V.   Enjoy Data
 "-"

-------------------------------------------------------------------------
SF.Net email is sponsored by: The Future of Linux Business White Paper
from Novell.  From the desktop to the data center, Linux is going
mainstream.  Let it simplify your IT future.
http://altfarm.mediaplex.com/ad/ck/8857-50307-18918-4
_______________________________________________
Pytables-users mailing list
Pytables-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/pytables-users

Reply via email to