[SciPy-User] [ANN] Fortranformat - Fortran format emulation for Python
Sun Oct 9 08:24:27 CDT 2011
Fortranformat is a library that emulates the functionality of FORTRAN
format statements in Python.
>>> import fortranformat as ff
>>> line = ff.FortranRecordReader('(4I4)')
>>> line.read(' 1 2 3 4')
[1, 2, 3, 4]
>>> line = ff.FortranRecordWriter('(4I4)')
>>> line.read([1, 2, 3, 4])
' 1 2 3 4'
It is extensively unit tested (to a degree that I was able to file a
bug report or two to the gfortran people!) but not tested in practice.
I'd appreciate some feedback.
It is available on PyPi and the project homepage is
Try it out with:
pip install fortranformat
More information about the SciPy-User