[Numpy-discussion] Appending a numpy array to existing text file

LB berthe.loic@gmail....
Tue Nov 27 12:30:43 CST 2007


If you just want to add your matrix to an existing ascii file, you can
open this file in append mode and give the file handle to
numpy.savetxt :

f_handle = file('my_file.dat', 'a')
savetxt(f_handle, my_matrix)
f_handle.close()

HTH

--
LB


More information about the Numpy-discussion mailing list