[Numpy-discussion] proposal: add a header and footer function to numpy.savetxt

Tim Michelsen timmichelsen at gmx-topmail.de
Thu Jul 17 09:15:15 EDT 2008


Hello,
sometime scripts and programs create a lot of data output.
For the programmer and also others not involved in the scripting but in the
evaluation of the output it would be very nice the output files could be
prepended with a file header describing what is written in the columns below and
to append a footer.

A good example has been developed by the scipy.scikits.timeseries developers:
http://scipy.org/scipy/scikits/wiki/TimeSeries#Parameters

These formatting flags are a convenient way to save additional meta information.
E. g. of it is important to state the physical units of the data saved.

I would be happy if such a thing could be added to np.savetxt().

What is the current common way to save a header above the saved ascii array?

Kind regaed,
Timmie






More information about the NumPy-Discussion mailing list