[Numpy-discussion] Extracting data from genfromtxt?

Ben Gamari bgamari.foss@gmail....
Fri Mar 18 20:52:38 CDT 2011

On Fri, 18 Mar 2011 20:27:17 +0000, Rohaq <rohaq@dearinternet.com> wrote:
> There could be a lot more than 2 other columns, Result3,Result4, etc.,
> so I need to code it to be scalable; if this were acting like a normal
> dict, I could write a loop that iterates over the keys, and loads the
> results data into a new object, but I can't seem to find a function
> that will return the keys so that I can do this.
You could also iterate over data.dtype.fields, which will behave much
like dict.keys().

- Ben

More information about the NumPy-Discussion mailing list