NumPY: Reading/Writing Arrays To/From Files

Grant Griffin not.this at seebelow.org
Wed Mar 28 16:21:49 CEST 2001


Ben Held wrote:
> 
> I would like to be able to read/write NumPY array objects to/from ascii
> files.  I could not find support for this in the NumPY code.  Any ideas?
> 
> Ben

I forget exactly, but I think there's something out there called
"arrayio".  Look for Travis Oliphant's page: I think you can find it
there.

Alternatively, you can do what I did once, which is to code it up
yourself using a Python list, then convert the list into a NumPy array. 
(This is probably slower than arrayio, but it works.)

necessity-is-the-mother-of-invention-ly y'rs,

=g2
-- 
_____________________________________________________________________

Grant R. Griffin                                       g2 at dspguru.com
Publisher of dspGuru                           http://www.dspguru.com
Iowegian International Corporation            http://www.iowegian.com



More information about the Python-list mailing list