statsmodels.iolib.foreign.savetxt
statsmodels.iolib.foreign.savetxt(fname, X, names=None, fmt='%.18e', delimiter=' ') [source]
Save an array to a text file. This is just a copy of numpy.savetxt patched to support structured arrays or a header of names. Does not include py3 support now in savetxt. Parameters:
fname : filename or file handle If the filename ends in .gz, the file is automatically saved in compressed gzip format. loadtxt understands gzipped files transparently. X : array_like